On Wed, 18 Jul 2001, Roman Black wrote: > Michael A. Powers wrote: > > > > Hello, > > > > I have been experimenting with TMR0 and the prescaler to provide timing delays in my > > application. It seems pretty easy to do if you want short delays. However, when > > you are using a 4MHz clock, it seems to get difficult to get long delays, say like > 1s. > > > At 4MHz, that's orders of magnitude away from a 1s delay, and I would like to have > > delays of 24 hrs or more! > > > Hi Michael, I have some sample code on my web page: > http://centauri.ezy.net.au/~fastvid/one_sec.htm I can vouch for this approach. I used a C implementation in a job I am just finishing up, and it's perfect. Bob Ammerman and Roman Black, I owe you each a beer or three. My clock now has NO drift other than whatever the crystal introduces -- I think we can live with 50PPM! 8-) Dale -- A train stops at a train station. A bus stops at a bus station. On my desk I have a workstation... -- http://www.piclist.com hint: The PICList is archived three different ways. See http://www.piclist.com/#archives for details.