make sure timer is initialised properly
Reported-by: jv4779 <jv4779@gmail.com>
This commit is contained in:
parent
143398705c
commit
be81a13584
4
timer.c
4
timer.c
|
|
@ -108,11 +108,11 @@ void timer_init()
|
||||||
// no outputs
|
// no outputs
|
||||||
TCCR1A = 0;
|
TCCR1A = 0;
|
||||||
// Normal Mode
|
// Normal Mode
|
||||||
TCCR1B |= MASK(CS10);
|
TCCR1B = MASK(CS10);
|
||||||
// set up "clock" comparator for first tick
|
// set up "clock" comparator for first tick
|
||||||
OCR1B = TICK_TIME & 0xFFFF;
|
OCR1B = TICK_TIME & 0xFFFF;
|
||||||
// enable interrupt
|
// enable interrupt
|
||||||
TIMSK1 |= MASK(OCIE1B);
|
TIMSK1 = MASK(OCIE1B);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef HOST
|
#ifdef HOST
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue