Timex M851 Скачать руководство пользователя страница 11

M851 WristApp GUI Plug-in Design Guide 

 

Rev 1.0 

Timex Corporation 

 

 

8

3.3.2  Changed WristApp Data 

 
When the database changes between downloads, the packager (TUCP.DLL) checks the size of the 
database and the contents versus the last data sent to the watch. If the size of the new data is larger than 
the previously allocated space, then a full download will occur. There is no call that needs to be done in 
order for this to occur. The packager handles this for you. All that is required is that the database differs in 
some way versus the previously downloaded database. If the database is the same size, yet the contents 
are different, then the database will be re-downloaded, but the code will not have to be downloaded 
again. This applies to all applications with database data associated with them. 
 

3.3.3  Reading WristApp Data 

 
If the WristApp has been modified in the watch, it will be uploaded back to the PC when the next read 
occurs, which happens when the watch is connected to the PC. The packager DLL reads the files and 
puts it into the DB directory in the PIM’s installation directory. 
 
Each wristapp that has been uploaded back to the PC will have the name upwristappdbX.bin where X is 
the instance of the application. When downloading, the PIM will place the instance number in the 
WristApp’s associated .INI file (which is created if it doesn’t exist). The file shown below describes how 
the INI file will be created: 
 
[System] 
Instance=5 
 
In the example above, the WristApp has an instance of 5, so the WristApp’s file will be upwristappdb5.bin. 
When the user double-clicks on your WristApp in the PIM’s mode list, you can read this file before 
showing the user interface and show the changes to the user. 
 
If the above Instance value was NULL (no value to the right of the equals sign), then that means no data 
was read for the WristApp. In this case, you should provide default data for the user when the UI 
launches. 
 
This file should be the same format as the database that was downloaded, and its up to the WristApp 
code to make sure that the database stays the same. 
 

4 Trademarks 

TIMEX is a registered trademark and service mark of Timex Corporation. 
TIMEX DATA LINK and WristApp are trademarks of Timex Corporation in the U.S. and other countries. 
Night-Mode is a registered trademark of Timex Corporation. 
INDIGLO is a registered trademark of Indiglo Corporation. 
 

Содержание M851

Страница 1: ...M851 WristApp GUI Plug in Design Guide Timex Corporation March 31 2003 ...

Страница 2: ...M851 WristApp GUI Plug in Design Guide Rev 1 0 DOCUMENT REVISION HISTORY REVISION 1 0 DATE 5 06 2003 AUTHOR Brigham W Thorp AFFECTED PAGES DESCRIPTION All Created document Timex Corporation i ...

Страница 3: ... THE APPLICATION 3 3 1 REQUIRED TOOLS 3 3 2 CREATING THE APPLICATION 3 3 2 1 Show Function 3 3 2 2 ProcessData Function 3 3 2 3 Creating the DLL 4 3 2 4 Example application World Time 6 3 3 WRISTAPP INFORMATION 7 3 3 1 Distributing the WristApp 7 3 3 2 Changed WristApp Data 8 3 3 3 Reading WristApp Data 8 4 TRADEMARKS 8 Timex Corporation ii ...

Страница 4: ...ristApp contains a database while the Pulse Wrist App does not The database associated with the WristApp gives the user the ability to add different data to the mode The WristApp GUI Plug in gives users the ability to change data within a WristApp database This document serves as a guide for developing a WristApp GUI Plug in for the PIM Personal Information Manager software 1 1 Applicable Document...

Страница 5: ... if the mode is a WristApp and has a GUI Plug in associated with it The PIM also handles calling the module that handles communicating data with the watch Finally the PIM contains all of the data editors for each of the built in modes The data editors themselves handle import plug ins that allow you to import data from different sources such as CSV files or schedules over the Internet The simple d...

Страница 6: ... modify data using a user interface This function is called by the PIM when the user double clicks on the WristApp entry in the mode list Typically this function will instantiate a class such as a dialog that is then shown When the user has finished with the dialog the updated database should be saved For consitency between applications Timex recommends using a dialog based class and saving data o...

Страница 7: ...application using Microsoft s Visual C 6 0 Step 1 Launch Microsoft Visual C Select File New Step 2 Select MFC AppWizard dll enter the name of the project as well as the project location then click on OK Step 3 Choose Regular DLL using shared MFC DLL and leave the other settings alone Click on Finish Timex Corporation 4 ...

Страница 8: ...own above place the definitions from the two entry points above Here is the example code for the WorldTime WristApp extern C BOOL FAR PASCAL EXPORT Show LPCTSTR lpszDataPath LPVOID pData Need to use this macro whenever we access resources from MFC DLL AFX_MANAGE_STATE AfxGetStaticModuleState CString sINIFile lpszDataPath sINIFile App TestApp ini CTestApp dlg dlg m_sIniFileName lpszDataPath dlg m_s...

Страница 9: ...t allows you to configure the different time zones within the WristApp As described above the Show and ProcessData functions are called by the PIM to launch the GUI Plug in In the World Time WristApp Plug in created using Microsoft s Visual C with MFC libraries there is a dialog class that handles such messages as WM_INITDIALOG BN_CLICKED for the OK and Cancel buttons as well as WM_DESTROY In addi...

Страница 10: ...and its operation This may also be a HTML file If there are graphics with the HTML they must be added to this directory as well application_name_PAR_018 BIN Parameter file required by M851 OS to initialize the wristapp in the system application_name_CODE_018 BIN WristApp code application_name_DBASE_018 BIN WristApp database file this file is created by the WristApp PC interface application_name DL...

Страница 11: ... directory Each wristapp that has been uploaded back to the PC will have the name upwristappdbX bin where X is the instance of the application When downloading the PIM will place the instance number in the WristApp s associated INI file which is created if it doesn t exist The file shown below describes how the INI file will be created System Instance 5 In the example above the WristApp has an ins...

Отзывы: