background image

8

Documentation Number PCRTC2095 Manual

B&B Electronics -- PO Box 1040 -- Ottawa, IL 61350

PH (815) 433-5100 -- FAX (815) 433-5105

Get_RTC_Time

Purpose : Returns the RTC time within a structure.

C:

struct GetTime_T {

unsigned int hours;
unsigned int min;
unsigned int seconds;
unsigned int h_seconds;

};

int Get_RTC_Time(GetTime_T far *gt);

Pascal :

TYPE GetTime_T = RECORD

hours: WORD;
min: WORD;
seconds: WORD;
h_seconds: WORD;

END;

TYPE GetTime_Ptr = ^GetTime_T;

FUNCTION Get_RTC_Time(time: GetTime_Ptr):
WORD;

BASIC:

TYPE GetTimeT

hours AS INTEGER
min AS INTEGER
seconds AS INTEGER
hseconds AS INTEGER

END TYPE

FUNCTION GetRTCTime%(BYVAL Offs AS INTEGER,
BYVAL Segm AS INTEGER)

Remarks: Get_RTC_Time requires a far pointer to the GetTime_T

structure to be past as the argument.

Returns:

The GetTime_T structure with the appropriate values.

Example:

See below.

Summary of Contents for PCRTC

Page 1: ...C2095 This product Designed and Manufactured In Ottawa Illinois USA of domestic and imported parts by B B Electronics Mfg Co Inc 707 Dayton Road P O Box 1040 Ottawa IL 61350 PH 815 433 5100 FAX 815 43...

Page 2: ...HARDWARE SETUP 2 TABLE 1 ADDRESS SWITCH SETTINGS 2 HARDWARE INSTALLATION 3 SOFTWARE SETUP 3 CHAPTER 3 OPERATION 4 OVERVIEW 4 USING THE DEVICE DRIVER 4 COMMAND LINE OPTIONS 5 SETTING THE PCRTC TIME AND...

Page 3: ...reset Packing List Examine the shipping carton and contents for physical damage The following items should be in the shipping carton 1 PCRTC unit 2 One PCRTC 3 5 disk 3 This instruction manual If any...

Page 4: ...factory set for 200h If you need to change this address select one from the table which will not conflict with another device in the host computer If the PCRTC does not operate properly select a new a...

Page 5: ...n Chapter 3 of this manual or by the device driver If you are using the device driver it will automatically initialize the PCRTC when it loads Upon initialization a warning will appear stating that th...

Page 6: ...take action on a low battery before the time is corrupted The second function is the time of last power loss or reset By checking this function the time of the last host computer power loss or system...

Page 7: ...CRTC c address Display PCRTC and DOS clock PCRTC u address Set PCRTC date time to DOS date time PCRTC n address Set DOS date time to PCRTC date time PCRTC h address Increment hours 1 for Daylight Savi...

Page 8: ...time to be updated to within 0 1 seconds of the atomic clock selected The small discrepancy in time is dependent on the speed of the host computer and background activities on the host computer Replac...

Page 9: ...RTC_API address WORD WORD BASIC FUNCTION StartRTCAPI BYVAL address AS INTEGER Remarks Start_RTC_API takes the address at which the PCRTC is installed at The device driver must be installed Returns 0 d...

Page 10: ..._T far gt Pascal TYPE GetTime_T RECORD hours WORD min WORD seconds WORD h_seconds WORD END TYPE GetTime_Ptr GetTime_T FUNCTION Get_RTC_Time time GetTime_Ptr WORD BASIC TYPE GetTimeT hours AS INTEGER m...

Page 11: ...ve_T far ts Pascal TYPE TimeSave_T RECORD month WORD day WORD hour WORD minute WORD second WORD END TYPE TimeSave_Ptr TimeSave_T FUNCTION Last_Power_Down_RTC timeSave TimeSave_Ptr WORD BASIC TYPE Time...

Page 12: ...imeS day PRINT at timeS hour timeS minute timeS second END IF IF BatteryRTC THEN Check Battery Status PRINT Battery Status GOOD ELSE PRINT Battery Status LOW END IF ELSE PRINT Device Driver PCRTCDD SY...

Page 13: ...gned int address cprintf Demo PCRTC c v1 00 c Copyright 1994 B B Electronics Mfg Co r n r n address Start_RTC_API 0 if address if Get_RTC_Time time cprintf RTC time u u u u r n time hours time min tim...

Page 14: ...dependent on the quality of the oscillator circuit There are three sources of error in the oscillator and understanding them will allow you to estimate the precision of the PCRTC in your application...

Page 15: ...he coldweld manufacturing technique which exhibits the lowest aging characteristic of 1 ppm year In practice this aging rate improves significantly with time but for practical purposes the value of 1...

Page 16: ...ontroller 8259A 040 043 timer 8253 060 063 PPI 8255A 080 083 DMA page register 74LS612 0A0 0AF NMI non maskable interrupt 200 20F game port joystick controller 210 217 expansion unit 2E8 2EF COM4 seri...

Page 17: ...ller 2 8237A 0F0 0FF 80287 math coprocessor 1F0 1F8 hard disk 200 20F game port joystick controller 258 25F Intel Above Board 278 27F parallel printer port 2 2E8 2EF COM4 serial port 2F8 2FF COM2 seri...

Reviews: