Timer issues

Jeremy Leach

Senior Member
I'm not convinced the Timer is working properly on 28X1.

I'm working at 16MHz, so a minor tick is 16us. If I run a timing routine using (a) major ticks of 1/500 seconds (preload = 65411) I get different timing results to if I use (b) major ticks of 1/250 seconds (preload = 65286) taking the tick differences into account.

(b) results are larger than (a) results.

I'm thinking it could have something to do with the ticks in (a) being too fast for the Picaxe to handle (update Timer variable), but this is a guess.
 

Technical

Technical Support
Staff member
Yes, your major ticks are simply too fast, timer was never designed to work this quickly and so will miss beats at this speed. Its designed for counting seconds, half seconds etc, not 1/500th of a second!
 
Top