Datasheet
ii
ATmega8515(L)
2512G–AVR–03/05
System Control and Reset................................................................ 44
Internal Voltage Reference................................................................................. 49
Watchdog Timer ................................................................................................. 49
Timed Sequences for Changing the Configuration of the Watchdog Timer ....... 52
Interrupts............................................................................................ 53
Interrupt Vectors in ATmega8515....................................................................... 53
I/O Ports.............................................................................................. 58
Introduction......................................................................................................... 58
Ports as General Digital I/O................................................................................ 59
Alternate Port Functions ..................................................................................... 63
Register Description for I/O Ports....................................................................... 74
External Interrupts............................................................................. 76
8-bit Timer/Counter0 with PWM........................................................ 79
Overview............................................................................................................. 79
Timer/Counter Clock Sources............................................................................. 80
Counter Unit........................................................................................................ 80
Output Compare Unit.......................................................................................... 81
Compare Match Output Unit............................................................................... 83
Modes of Operation ............................................................................................ 84
Timer/Counter Timing Diagrams......................................................................... 88
8-bit Timer/Counter Register Description ........................................................... 90
Timer/Counter0 and Timer/Counter1 Prescalers............................ 94
16-bit Timer/Counter1........................................................................ 96
Overview............................................................................................................. 96
Accessing 16-bit Registers ................................................................................. 99
Timer/Counter Clock Sources........................................................................... 102
Counter Unit...................................................................................................... 102
Input Capture Unit............................................................................................. 103
Output Compare Units...................................................................................... 105
Compare Match Output Unit............................................................................. 107
Modes of Operation .......................................................................................... 108
Timer/Counter Timing Diagrams....................................................................... 116
16-bit Timer/Counter Register Description ....................................................... 118
Serial Peripheral Interface – SPI..................................................... 125
SS Pin Functionality.......................................................................................... 129
Data Modes ...................................................................................................... 132