piclist 2002\11\27\061829a >
Thread: Clock accuracy
www.piclist.com/techref/microchip/time.htm?key=clock
face
flavicon
face BY : Russell McMahon email (remove spam text)



> To get  a period of 250 out of TMR2 you set the PR2 register to 249!

And bingo, Bob's your uncle.
251/250 too long = 1 in 250 = 1 extra second per 4 minutes 10 seconds.
QED.

I think Bob, and Andrew Warren with a more general take on the same thing,
have hit the nail on the head.


       RM

> > > I initialized TMR2 with prescaler 4, postscaler 1:1 and period 250.
> > > ....
> > > clock lags behind about a second in 4 minutes. IMHO, the error is
> > > too big to fix it only in software. So there must be something else
> > > wrong.
> >

--
http://www.piclist.com hint: To leave the PICList
spamBeGonepiclist-unsubscribe-requestEraseMEspamspammitvma.mit.edu


<009601c29606$82d40b60$2301a8c0@Paradise> 7bit

See also: www.piclist.com/techref/microchip/time.htm?key=clock
Reply You must be a member of the piclist mailing list (not only a www.piclist.com member) to post to the piclist. This form requires JavaScript and a browser/email client that can handle form mailto: posts.
Subject (change) Clock accuracy

month overview.

new search...