I have two Compare Interrupts on my Yun.
Everything works fine.
But when i look at the balance that when the interrupts run the code i feel confused.
Maybe somebody can help me.
Timer 3, 16 Bit, Prescaler 64 Interrupt run every 257ms, OCR3A = 64249
When i compare the mills() the timer is running, most ist 257ms.
but sometimes after 10, 20, 5, 12 ... .. .. cycles sometimes the timer run after 256ms or also 258ms.
is the a feature or something else for making the timer exactly similar like embedded systems?
i write these Data into DB.
I write 4100 Lines in Database and 252 Times the Time is wrong.
Diff -1: 128 Times
Diff +1:122 Times
Diff +2: 2 Times
Timer init is:
TCCR3A = 0;
TCCR3B = (1 << WGM32) | (1 << CS31) | (1 << CS30);
TCCR3C = 0;
TCNT3 = 0;
OCR3A = 64249;
TIMSK3 = (1 << OCIE3A);
Who know how i can resolve this Problem?