astralien3000 / aversive--

API to ease microcontroller programming
GNU General Public License v3.0
11 stars 0 forks source link

Timer 1 interrupts doesn't work #29

Closed astralien3000 closed 10 years ago

astralien3000 commented 10 years ago

I really have to fix the problem with timers

Elioty commented 10 years ago

Is it really only for one timer? The others work properly? :astonished:

astralien3000 commented 10 years ago

Timer 0 works well (because our robot wouldn't have moved if it did not). Timer 2 and 3 (if it exists on the microcontroller) are not even managed by the .archi files.

Elioty commented 10 years ago

Yeah timer 0 is used by the scheduler. Does timer 1 exist on every AVR? Because we could maybe, one day, implement Aversive::sleep with it.

For timer 2 and 3, for the microcontrollers that have them, we should add them one day or another. Likewise for the missing pins on Atmega2560, I will add them because I need them anyway to fully implement my Arduino 2560 mega's pin map (well, it is actually already done, just have to take the time to commit and push).

benoit-gilbert commented 10 years ago

did you do the same than in scheduler.cpp or you forgot something ? (i see : init(), setPrescaler(), overflowEvent().setFunction() and overflowEvent().start())

astralien3000 commented 10 years ago

It is not a single test that doesn't work, every time that I used timer 1 it didn't work, and timer 0 is ok with the same code.