ATmega48/88/168
13 I/O-Ports .................................................................................................. 72
13.1Overview ................................................................................................................72
13.2Ports as General Digital I/O ...................................................................................73
13.3Alternate Port Functions ........................................................................................77
13.4Register Description ..............................................................................................88
14 8-bit Timer/Counter0 with PWM ............................................................ 90
14.1Features ................................................................................................................90
14.2Overview ................................................................................................................90
14.3Timer/Counter Clock Sources ...............................................................................92
14.4Counter Unit ..........................................................................................................92
14.5Output Compare Unit .............................................................................................93
14.6Compare Match Output Unit ..................................................................................94
14.7Modes of Operation ...............................................................................................95
14.8Timer/Counter Timing Diagrams .........................................................................100
14.9Register Description ............................................................................................102
15 16-bit Timer/Counter1 with PWM ........................................................ 109
15.1Features ..............................................................................................................109
15.2Overview ..............................................................................................................109
15.3Accessing 16-bit Registers ..................................................................................111
15.4Timer/Counter Clock Sources .............................................................................114
15.5Counter Unit ........................................................................................................115
15.6Input Capture Unit ...............................................................................................116
15.7Output Compare Units .........................................................................................118
15.8Compare Match Output Unit ................................................................................120
15.9Modes of Operation .............................................................................................121
15.10Timer/Counter Timing Diagrams .......................................................................128
15.11Register Description ..........................................................................................131
16 Timer/Counter0 and Timer/Counter1 Prescalers .............................. 138
16.1Register Description ............................................................................................140
17 8-bit Timer/Counter2 with PWM and Asynchronous Operation ...... 141
17.1Features ..............................................................................................................141
17.2Overview ..............................................................................................................141
17.3Timer/Counter Clock Sources .............................................................................142
17.4Counter Unit ........................................................................................................142
17.5Output Compare Unit ...........................................................................................143
iii
2545M–AVR–09/07