
Filer Resource
Filer resource (system memory that Filer is using) can be referred.

The system memory is defined in rupsys.h.

    "System structure SYSTEMCTL *pSystemCtl"

The member of this structure includes the structure that is explained in the next section and can be referred by the same manner of accessing to a pointer of the usual structure.

If this access is not done correctly, system error or run away of the system may occur.  Therefore, you should be careful about this operation.


typedef struct {
    EVENTMANAGE *EventManager;  /* Event management                                             */
    PARAMSYS *Paramsys;         /* System parameter                                             */
    int *SystemPower;           /* Automatic power on/off status                                */
    WatchDT *CPUram;            /* Time                                                         */
    RUPSYS *RupDefine;          /* onHand/Ruputer system definition structure area (system.ini) */
    int *RupRelatedSize;        /* Number of file associated definition structure area          */
    RELATED *RupRelated;        /* File associated definition structure area                    */
    int *FileInfoSize;          /* Number of file information                                   */
    FILEINFO *FileInfo;         /* File information (not sorted)                                */
    FILEINFO **FileList;        /* File information list (sorted)                               */
    char *DirectoryPath;        /* Current directory path                                       */
    int *DirectoryTree;         /* Depth of path                                                */
    int *BLDReq;                /* BLD confirmation request                                     */
    int *BLD;                   /* BLD detection result                                         */
    int *BLDExecute;            /* Battery exchange EXF start request                           */
    unsigned int *MelodyPlay;   /* Playing melody buffer                                        */
    int *Secret;                /* Display/Hide of secret information                           */
    STW *STWdata;               /* Stop watch                                                   */
    int *repflg;                /* Repeat status of a button                                    */
    int *TimerStat;             /* Timer control (status)                                       */
    Tdata *TIMERdata;           /* Timer control (time)                                         */
} SYSTEMCTL;


Cautions
User application can refer to the values of the following Filer resources.  However, you must not change the setting values. 
 1.System file   B:\system\system.ini
 2.Filer resource *pSystemCtl->RupDefine (onHand/Ruputer system definition structure area)


[Current Time]
For example, acquire the time information that Filer has.

        /* Date and Time information */
        typedef struct{
            int yy;
            int mm;
            int dd;
            int h;
            int m;
            int s;
        } st_RTM;

        static st_RTM RTM;

        void GetSysTime(void)
        {
            /* Acquire date information */
            RTM.yy=pSystemCtl->CPUram->NOW_Year;
            RTM.mm=pSystemCtl->CPUram->NOW_Month;
            RTM.dd=pSystemCtl->CPUram->NOW_Day;

            /* Acquire time information */
            RTM.h=pSystemCtl->CPUram->NOW_Hour;
            RTM.m=pSystemCtl->CPUram->NOW_Min;
            RTM.s=pSystemCtl->CPUram->NOW_Sec;
        }

[1Hz Event]
For example, you can enable 1Hz event that Filer controls.
        pSystemCtl->EventManager->eventReq |= EVENT_SEC;
When you set it to invalid,
        pSystemCtl->EventManager->eventReq &= ~EVENT_SEC;

By setting this, you can handle 1Hz display process within the button process routine.  Please refer to <rupsysLibManu(c).txt> Keyin().




Structure definition in rupsys.h
The following is a brief explanation about the structure that is defined in rupsys.h.


1)File information structure FILEINFO
 The directory information under the specified directory and location of file information.
 It consists of Writing time/date&time/file size/file attribute/file name.
 The file name stores ASCIIZ.  Member time/date/attr is DOS format.


2)Watch structure WatchDT
This is mainly used to operate the real-time.


3)Stop watch structure STW
 This is used to control the time value for stop watch.
 This consists of ms/sec/min/hour.


4)Event control structure EVENTMANAGE
 All events are controlled in order for Filer to control or to pass the events to an application. 

 The described event in rupsys.h for eventReq and event are shown by bit.
 When the event that is specified in the EventReq request is generated, the result is shown to the event.


 WEEKday1/ WEEKday2/ WEEKday3/ WEEKday4 show the day of week by bit position as follows.

  WEEKLY_MON  0x0001  /* Mon   */
  WEEKLY_TUE  0x0002  /* Tue   */
  WEEKLY_WED  0x0004  /* Wed   */
  WEEKLY_THU  0x0008  /* Thu   */
  WEEKLY_FRI  0x0010  /* Fri   */
  WEEKLY_SAT  0x0020  /* Sat   */
  WEEKLY_SUN  0x0040  /* Sun   */

  POFFtime/ PONtime/WEEKtime1/ WEEKtime2/ WEEKtime3/ WEEKtime4 consists of time (15~6bit) and minute (5~0bit).
 ALMtime/USR1time/USR2time/USR3time consists year-1900 (31~20bit), month (19~16bit), date (15~11bit), hour (10~6bit) and minute (5~0bit).


5)Hour/Minute structure HOURTIME


6)System definition structure RUPSYS
 This is the structure that shows the system value of Filer and hardware setting values.
 Any modification of the values should be done by the feature setting application and secret setting application.
 The structure is 256 byte.


7)Associated definition structure RELATED
 This specifies the display/hide of the file with the specified extension, icons for list display, icons for icon display and application that uses the file as data.


8)Weekly alarm definition structure WEEKLYTABLE
 This is the area definition where the contents of WEEKLY.INI file that the watch application created is stored.
 and[] is the specification of the sound file that sounds the week alarm when the time is matched.
 If the extension is ".SND" and file name is 8 characters, NULL is excluded.


9)User alarm definition structure EVENTTABLE
 This is the definition structure that stores the contents of ALARM.INI file that the schedule application and user application updated.


10)Time definition structure for count down timer Tdata


11)Structure definition of apc functions MENU, ERRmess


12)System parameter structure PARAMSYS
 System parameter area definition


13)System structure SYSTEMCTL
 This is the structure that passes the resources of the Filer to an application.




Structure definition in softkey.h
The structure that is used for soft keyboard is defined.




ini file
ini file that system uses as follows.
ini file that the Filer uses are located in B:\system directory.


In addition, ini file that an application uses are located in B:\system\ini directory.


The following is the list of ini file that system uses.

system.ini
 This file has RUPSYS structure 256 byte file size.
 -> *The setting values of this structure for user application must not be changed.

alarm.ini
 This file has EVENTTABLE structure x 4 file size.
 Refer to <09_ChildProcess.txt>.

weekly.ini
 This file has WEEKLYTABLE structure x 4 file size.
 Refer to <10_INIfile.txt>.

filer.ini
 This file has RELATED structure x associated total number file size.
 Refer to <10_INIfile.txt>.

subject2.ini
 Some style guide of onHand/RuputerPCtool are available.

===============================================================================
 Copyright (c) 1998-1999.  Seiko Instruments Inc.  All rights reserved. 
===============================================================================
