Stop Watch Gator using millis()
10:00.96 9:58.557
5:25.00 5:23.746
3:00.72 3:00.025
1:16.15 1:15.823
Any ideas on how to improve this or another method might be helpful. I
need to be accurate to a tenth of a second.
Specifically, on the Gator the millis() function runs too slowly by a
factor of 255/256. Any result from millis() therefore should be scaled
by 256/255 for better accuracy.
Please see the 'wiring.c' file uploaded to the Files section of this
group. It hasn't been thoroughly tested but it should fix the problem
with millis() by using a more accurate scheme.
Make a backup of the 'wiring.c' file in your current Arduino directory
(should be in hardware/cores/arduino/wiring.c) and replace it with the
file described above. Then recompile your code.