This simple example shows how to use the Timer/Counter (TC) Timeout Driver to toggle two LEDs at different speeds.
The driver can be found here.
All megaAVR devices with a Timer/Counter module can be used.
The following connections are required on STK600 for this example:
The example will configure a tick speed of 1024 Hz and use two different periodic timeouts to toggle two different LEDs. One will toggle at 1Hz and the other at 1/3Hz.
This software was written for the GNU GCC for AVR. Other compilers may or may not work.
For further information, visit Microchip.