klg0582@uxa.cso.uiuc.edu (Ken-Huang Lin) (09/13/90)
When I ran a housekeeping program for a few days, I found that the system date wouldn't get updated. Could anyone tell me why is so and how to prevent it? I am running Dos 3.3. Thanks a lot, Ken H. Lin lin@uiwpl.ece.uiuc.edu
wales@valeria.cs.ucla.edu (Rich Wales) (09/19/90)
In article <1990Sep13.041153.21544@ux1.cso.uiuc.edu> klg0582@uxa.cso.uiuc.edu (Ken-Huang Lin) writes: When I ran a housekeeping program for a few days, I found that the system date wouldn't get updated. Could anyone tell me why is so and how to prevent it? I am running Dos 3.3. PC's of most kinds handle the date in a sloppy manner. Specifically, if the system never asks for the current date during a period of time stretching over one or more complete days, the date will not be updated properly. The reason for this is that the system keeps track of date overflow (at midnight) via a binary flag. It doesn't count days -- it just notes that midnight happened. Thus, when the system next accesses the date, it assumes that only one day has passed. There is a related bug which can cause a date rollover to be lost if the wrong software is the first to ask about the date/time just after mid- night. Since the date processing is handled within DOS, there is no truly portable fix to this problem. If you have a clock/calendar card built around the National Semiconduc- tor MM58167A chip, you can try my clock driver on WSMR-SIMTEL20.ARMY.MIL in the file PD1:<MSDOS.SYSUTL>MMCLK12.ZIP. This "freeware" program gets the date and time directly from the clock/calendar card at all times -- bypassing DOS (and the problem you encountered). Many clock/calendar cards for PC's and XT's -- including most of those which use a cheapo program called TIMER.COM to initialize the date and time from the card -- use the MM58167A chip and can benefit greatly from my driver. -- -- Rich Wales <wales@CS.UCLA.EDU> // UCLA Computer Science Department 3531 Boelter Hall // Los Angeles, CA 90024-1596 // +1 (213) 825-5683 "We would all become unpeople, undoing unthings untogether. Fascinating."