real-time clock interface
The rtc driver supports the real-time clock chip,
allowing it to be set with the correct local time
and allowing the time to be read from the chip.
The following ioctl calls are supported.
This call is used to read the local time from the real-time
clock chip. The argument to the
is the address of a buffer of
RTC_NREG unsigned characters
(RTC_NREG is defined as <sys/rtc.h>).
The ioctl will fill in the buffer with the
contents of the chip registers. Currently,
RTC_NREG is 14, and the meanings of the byte
registers are as follows:
Day of week
Date of month
Year within century.
Values in the range 69-99 refer to years in the twentieth
century (1969 to 1999 inclusive); values in the range 00-68
refer to years in the twenty-first century (2000 to 2068
Status register A
Status register B
Status register C
Status register D
For further information on the functions of these registers,
see your hardware technical reference manual.
This call is used to set the time into the real-time clock chip.
The argument to the ioctl is the address of a buffer of
RTC_NREGP unsigned characters
(RTC_NREGP as defined in <sys/rtc.h>).
These bytes should be the desired chip register contents.
is 10, representing registers 0-9 as shown above.
Note that only the superuser may open the
real-time clock device for writing and that the
RTCSTIME ioctl will fail
for any other than the superuser.
© 2005 The SCO Group, Inc. All rights reserved.
SCO OpenServer Release 6.0.0 -- 03 June 2005