CMOS: Difference between revisions

100 bytes added ,  4 years ago
[unchecked revision][unchecked revision]
(→‎Getting Current Date and Time from RTC: Fix range column lacking leading space for rows below header)
Line 152:
=== Weekday Register ===
 
The RTC chip is able to keep track of the current day of the week. All it does is increment its "Weekday" register at midnight and reset it to zero1 if itthe reachesincremented value would go above 7[https://groups.google.com/d/msg/alt.os.development/qPxWHKC48rw/yjAt-c8IAQAJ]. Unfortunately there is no guarantee that this register was ever set correctly by anything (including when the user changes the time and date using the BIOS configuration screen). It is entirely unreliable and should not be used.
 
The correct way to determine the current day of the week is to calculate it from the date (see [http://en.wikipedia.org/wiki/Weekday_determination the article on Wikipedia] for details of this calculation).
Anonymous user