User Manual

iii
ATmega48A/PA/88A/PA/168A/PA/328/P [DATASHEET]
8271E–AVR–07/2012
13.1Pin Change Interrupt Timing ..................................................................................71
13.2Register Description ..............................................................................................72
14 I/O-Ports ..................................................................................................76
14.1Overview ................................................................................................................76
14.2Ports as General Digital I/O ...................................................................................77
14.3Alternate Port Functions ........................................................................................81
14.4Register Description ..............................................................................................92
15 8-bit Timer/Counter0 with PWM ............................................................ 94
15.1Features ................................................................................................................94
15.2Overview ................................................................................................................94
15.3Timer/Counter Clock Sources ...............................................................................95
15.4Counter Unit ..........................................................................................................95
15.5Output Compare Unit .............................................................................................96
15.6Compare Match Output Unit ..................................................................................98
15.7Modes of Operation ...............................................................................................99
15.8Timer/Counter Timing Diagrams .........................................................................103
15.9Register Description ............................................................................................105
16 16-bit Timer/Counter1 with PWM ........................................................ 112
16.1Features ..............................................................................................................112
16.2Overview ..............................................................................................................112
16.3Accessing 16-bit Registers ..................................................................................114
16.4Timer/Counter Clock Sources .............................................................................117
16.5Counter Unit ........................................................................................................118
16.6Input Capture Unit ...............................................................................................118
16.7Output Compare Units .........................................................................................120
16.8Compare Match Output Unit ................................................................................122
16.9Modes of Operation .............................................................................................123
16.10Timer/Counter Timing Diagrams .......................................................................130
16.11Register Description ..........................................................................................132
17 Timer/Counter0 and Timer/Counter1 Prescalers ............................... 139
17.1Internal Clock Source ..........................................................................................139
17.2Prescaler Reset ...................................................................................................139
17.3External Clock Source .........................................................................................139
17.4Register Description ............................................................................................141
18 8-bit Timer/Counter2 with PWM and Asynchronous Operation ....... 142