ATMEGA168-20PI Atmel, ATMEGA168-20PI Datasheet - Page 203
ATMEGA168-20PI
Manufacturer Part Number
ATMEGA168-20PI
Description
IC AVR MCU 16K 20MHZ 28DIP
Manufacturer
Atmel
Series
AVR® ATmegar
Specifications of ATMEGA168-20PI
Core Processor
AVR
Core Size
8-Bit
Speed
20MHz
Connectivity
I²C, SPI, UART/USART
Peripherals
Brown-out Detect/Reset, POR, PWM, WDT
Number Of I /o
23
Program Memory Size
16KB (8K x 16)
Program Memory Type
FLASH
Eeprom Size
512 x 8
Ram Size
1K x 8
Voltage - Supply (vcc/vdd)
2.7 V ~ 5.5 V
Data Converters
A/D 6x10b
Oscillator Type
Internal
Operating Temperature
-40°C ~ 85°C
Package / Case
28-DIP (0.300", 7.62mm)
Lead Free Status / RoHS Status
Contains lead / RoHS non-compliant
- Current page: 203 of 378
- Download datasheet (8Mb)
20.6.1
20.6.2
2545S–AVR–07/10
Transmitter and Receiver Flags and Interrupts
Disabling the Transmitter or Receiver
Note:
The RXCn, TXCn, and UDREn flags and corresponding interrupts in USART in MSPIM mode
are identical in function to the normal USART operation. However, the receiver error status flags
(FE, DOR, and PE) are not in use and is always read as zero.
The disabling of the transmitter or receiver in USART in MSPIM mode is identical in function to
the normal USART operation.
Assembly Code Example
C Code Example
USART_MSPIM_Transfer:
USART_MSPIM_Wait_RXCn:
unsigned char USART_Receive( void )
{
}
; Wait for empty transmit buffer
sbis UCSRnA, UDREn
rjmp USART_MSPIM_Transfer
; Put data (r16) into buffer, sends the data
out UDRn,r16
; Wait for data to be received
sbis UCSRnA, RXCn
rjmp USART_MSPIM_Wait_RXCn
; Get and return received data from buffer
in r16, UDRn
ret
/* Wait for empty transmit buffer */
while ( !( UCSRnA & (1<<UDREn)) );
/* Put data into buffer, sends the data */
UDRn = data;
/* Wait for data to be received */
while ( !(UCSRnA & (1<<RXCn)) );
/* Get and return received data from buffer */
return UDRn;
1.
See ”About Code Examples” on page 7.
(1)
(1)
ATmega48/88/168
203
Related parts for ATMEGA168-20PI
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
Part Number:
Description:
Manufacturer:
Atmel Corporation
Datasheet:
Part Number:
Description:
Manufacturer:
Atmel Corporation
Datasheet:
Part Number:
Description:
Manufacturer:
ATMEL Corporation
Datasheet:
Part Number:
Description:
IC AVR MCU 16K 20MHZ 32TQFP
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
IC AVR MCU 16K 20MHZ 32-QFN
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
IC AVR MCU 16K 20MHZ 28DIP
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
MCU AVR 16K FLASH 15MHZ 32-TQFP
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
MCU AVR 16K FLASH 15MHZ 32-QFN
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
IC AVR MCU 16K 20MHZ 32TQFP
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
MCU AVR 16KB FLASH 20MHZ 32QFN
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
MCU AVR 16KB FLASH 20MHZ 32TQFP
Manufacturer:
Atmel
Datasheet:
Part Number:
Description:
IC MCU AVR 16K FLASH 32-QFN
Manufacturer:
Atmel
Datasheet: