rocketscream / Low-Power

Low Power Library for Arduino
www.rocketscream.com
1.26k stars 345 forks source link

Include Timer3 for ATMega1284 #101

Open glyndavidson opened 4 years ago

glyndavidson commented 4 years ago

In the current library, you can only turn on/off timers 0, 1 and 2 for the Atmega1284p. However, this chip has 4 timers: 0, 1, 2 and 3.

See Peripheral features on page 1 of datasheet:

Peripheral Features – Two 8-bit Timer/Counters with Separate Prescalers and Compare Modes – Two 16-bit Timer/Counter with Separate Prescaler, Compare Mode, and Capture Mode

and on page 110 of datasheet:

14. 16-bit Timer/Counter1 and Timer/Counter3 with PWM

Please update the library for the ATMega1284p.

Please also include the ATMega1284 (non P variant) for barebones/breadboard/DIP versions.