Timex M851 Watch User Manual


 
M851 WristApp Design Guide Rev 1.2
Timex Corporation 59
Sample code for a one-line mode banner message:
lcdBannerMsg_CHRONO:
db LCDBANNER_COL5
db DM5_C, DM5_H, DM5_R, DM5_O, DM5_N, DM5_O
db LCD_END_BANNER
Sample code for a one-line mode banner message in the second line:
lcdBannerMsg_CHRONO:
db LCDBANNER_COL1
db LCDBANNER_COL5
db DM5_C, DM5_H, DM5_R, DM5_O, DM5_N, DM5_O
db LCD_END_BANNER
4.14 Mode Change
The kernel provides a number of macros to provide an application control in changing the foreground
application. During a mode change, including popups, the core will execute the following operations prior
to giving control to the new foreground state handler:
1. Execute Resource Handler previous application with the COREEVENT_TASKEXIT.
2. Clear all display update request flags on all kernel resources.
3. Clear entire display.
4. Cancel all switch depressions.
5. Cancel all timeouts.
6. Blinking is cancelled.
7. Scrolling is cancelled.
8. CORECurrentState is set to COREDEFAULTSTATE.
9. CORECurrentEvent is set to COREEVENT_STATEENTRY
10. CORECurrentASDAddress is set to the foreground application ASD address.
11. CORECurrentADDAddress is set to the foreground application ADD address
12. Copy Common Code from EEPROM to overlay area located after ASD.
13. Copy State 0 from EEPROM to overlay area located after common code.
USER INTERFACE NOTES:
The application will use the macro CORE_REQ_MODE_CHANGE_NEXT to change to the next
mode. The kernel will make the determination if it should proceed to the next mode or go back to
TOD mode. The kernel will keep track if the user intended to go back to primary mode or just
peeking into the primary mode.
The application can use the macro CORE_REQ_MODE_CHANGE_NEXT_NO_PEEK to change to
the next mode or the primary mode without the peek at primary mode option.
For a timer application in a CDC operation, it will request a special mode change macro that will
bypass displaying the application banner and directly execute the default state.
4.15 State Change
During a state change, the core will execute the following operations prior to giving control to the state
handler:
1. If the state change request macro used is CORE_REQ_STATE_CHANGE then the entire
display is cleared. If the macro used is
CORE_REQ_STATE_CHANGE_NO_CLEAR_DISPLAY, then the display is not cleared.