Wednesday 23 November 2011

Arduino/Atmega168 Timers For Sleeping

The following is a table outlining the available timers of the Arduino, their max timeout period (how long you can put your Arduino to sleep for) and the lowest power saving mode that the timer can be used in. I hope it will help you in your choice of sleep timer.


Timer Size Max Timeout Period Min Power Mode
Timer0
8 bit
16.4ms
IDLE
Timer1
16 bit
4.1s
IDLE
Timer2
8 bit
16.4ms
POWER_SAVE
Watch Dog Timer
N/A
8s
PWR_DOWN


Note PWR_DOWN is the power mode with the least power consumption. Please refer to Part 1 Overview Of Arduino Sleep Modes for a description of the available power modes.


Details for the use of timers and watch dog for sleep control can be found in parts 4 and 5 of the Sleeping Arduino Series.


If you need a longer sleep period than 8 seconds, and don't want to manage a software timer that is ticked every 8 seconds, then you could consider an external real-time clock such as:
http://proto-pic.co.uk/deadon-rtc-ds3234-breakout/

No comments:

Post a Comment