🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ibm.pc.misc
Article #3255

Re: DOS date update

#3255
From: Rich Wales
Date: Tue, 18 Sep 1990 22:02
38 lines
2328 bytes
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."
Technical Details
Message-ID: <39073@shemp.CS.UCLA.EDU>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!orion.oac.uci.edu!ucivax!ucla-cs!valeria.cs.ucla.edu!wales
References: <1990Sep13.041153.21544@ux1.cso.uiuc.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!orion.oac.uci.edu!ucivax!ucla-cs!valeria.cs.ucla.edu!wales
From: wales@valeria.cs.ucla.edu (Rich Wales)
Newsgroups: comp.sys.ibm.pc.misc
Subject: Re: DOS date update
Message-ID: <39073@shemp.CS.UCLA.EDU>
Date: 18 Sep 90 22:02:50 GMT
References: <1990Sep13.041153.21544@ux1.cso.uiuc.edu>
Sender: news@CS.UCLA.EDU
Reply-To: wales@CS.UCLA.EDU (Rich Wales)
Organization: UCLA CS Department, Los Angeles
Lines: 38