Datasheet
Port Pin Alternate Functions
PB1 T1 (Timer/Counter 1 External Counter Input)
CLKO (Divided System Clock Output)
PCINT9 (Pin Change Interrupt 9)
PB0 T0 (Timer/Counter 0 External Counter Input)
XCK0 (USART0 External Clock Input/Output)
PCINT8 (Pin Change Interrupt 8)
The alternate pin configuration is as follows:
• SCK/PCINT15 – Port B, Bit 7
– SCK: Master Clock output, Slave Clock input pin for SPI0 channel. When the SPI0 is enabled
as a slave, this pin is configured as an input regardless of the setting of DDB7. When the
SPI0 is enabled as a master, the data direction of this pin is controlled by DDB7. When the
pin is forced to be an input, the pull-up can still be controlled by the PORTB7 bit.
– PCINT15: Pin Change Interrupt source 15. The PB7 pin can serve as an external interrupt
source.
• MISO/PCINT14 – Port B, Bit 6
– MISO: Master Data input, Slave Data output pin for SPI channel. When the SPI0 is enabled
as a master, this pin is configured as an input regardless of the setting of DDB6. When the
SPI is enabled as a slave, the data direction of this pin is controlled by DDB6. When the pin is
forced to be an input, the pull-up can still be controlled by the PORTB6 bit.
– PCINT14: Pin Change Interrupt source 14. The PB6 pin can serve as an external interrupt
source.
• MOSI/PCINT13 – Port B, Bit 5
– MOSI: SPI Master Data output, Slave Data input for SPI channel. When the SPI0 is enabled
as a slave, this pin is configured as an input regardless of the setting of DDB5. When the SPI
is enabled as a master, the data direction of this pin is controlled by DDB5. When the pin is
forced to be an input, the pull-up can still be controlled by the PORTB5 bit.
– PCINT13: Pin Change Interrupt source 13. The PB5 pin can serve as an external interrupt
source.
• SS/OC0B/PCINT12 – Port B, Bit 4
– SS: Slave Port Select input. When the SPI is enabled as a slave, this pin is configured as an
input regardless of the setting of DDB4. As a slave, the SPI0 is activated when this pin is
driven low. When the SPI is enabled as a master, the data direction of this pin is controlled by
DDB4. When the pin is forced to be an input, the pull-up can still be controlled by the
PORTB4 bit.
– OC0B: Output Compare Match B output. The PB4 pin can serve as an external output for the
Timer/Counter0 Output Compare. The pin has to be configured as an output (DDB4 set “1”) to
serve this function. The OC0B pin is also the output pin for the PWM mode timer function.
– PCINT12: Pin Change Interrupt source 12. The PB4 pin can serve as an external interrupt
source.
• AIN1/OC0A/PCINT11– Port B, Bit 3
– AIN1: Analog Comparator Negative input. This pin is directly connected to the negative input
of the Analog Comparator.
Atmel ATmega644A [DATASHEET]
Atmel-42716C-ATmega644A_Datasheet_Complete-10/2016
104