ReadBattClockMem()
Synopsis
ULONG ReadBattClockMem(
ULONG offset,
ULONG length );
Function
Read a field of up to 32 bits out of the battery backed up memory
of the real time clock. This is the storage battmem.resource is
built on; normal applications should use that resource instead.
Result
The field, right aligned. Zero if the clock has no battery memory,
or if offset lies beyond the end of it.
Notes
Not all clock chips have battery backed up memory. The MSM6242B
fitted to some machines has none, and this function returns 0
there.
WriteBattClock()
Synopsis
void WriteBattClock(
ULONG time );
Function
Set the system's battery backed up clock to the time specified. The
value should be the number of seconds since 00:00:00 on 1.1.1978.
Result
The clock will be set.
Notes
This may not do anything on some systems where the battery backed
up clock either doesn't exist, or may not be writable.
WriteBattClockMem()
Synopsis
void WriteBattClockMem(
ULONG data,
ULONG offset,
ULONG length );
Function
Write a field of up to 32 bits into the battery backed up memory
of the real time clock. This is the storage battmem.resource is
built on; normal applications should use that resource instead.
Notes
Not all clock chips have battery backed up memory. The MSM6242B
fitted to some machines has none, and this function does nothing
there. Writes that start beyond the end of the battery memory are
ignored; writes that run past the end are truncated.