ATMEGA16U2-16AU Atmel, ATMEGA16U2-16AU Datasheet - Page 151

no-image

ATMEGA16U2-16AU

Manufacturer Part Number
ATMEGA16U2-16AU
Description
8-bit Microcontrollers - MCU 16K Flash
Manufacturer
Atmel
Datasheet

Specifications of ATMEGA16U2-16AU

Product Category
8-bit Microcontrollers - MCU
Rohs
yes
Core
AVR
Data Bus Width
8 bit
Program Memory Size
16 KB
Data Ram Size
1.25 KB
Data Rom Size
512 B
Program Memory Type
Flash
Factory Pack Quantity
1250
Table 18-1.
18.3.2
7799D–AVR–11/10
Operating Mode
Asynchronous Normal mode
(U2Xn = 0)
Asynchronous Double Speed
mode (U2Xn = 1)
Synchronous Master mode
Double Speed Operation (U2Xn)
Equations for Calculating Baud Rate Register Setting
Table 18-1
ing the UBRRn value for each mode of operation using an internally generated clock source.
Note:
Some examples of UBRRn values for some system clock frequencies are found in
page
The transfer rate can be doubled by setting the U2Xn bit in UCSRnA. Setting this bit only has
effect for the asynchronous operation. Set this bit to zero when using synchronous operation.
Setting this bit will reduce the divisor of the baud rate divider from 16 to 8, effectively doubling
the transfer rate for asynchronous communication. Note however that the Receiver will in this
case only use half the number of samples (reduced from 16 to 8) for data sampling and clock
recovery, and therefore a more accurate baud rate setting and system clock are required when
this mode is used. For the Transmitter, there are no downsides.
172.
BAUD
f
UBRRn
OSC
1. The baud rate is defined to be the transfer rate in bit per second (bps)
contains equations for calculating the baud rate (in bits per second) and for calculat-
Equation for Calculating Baud Rate
BAUD
BAUD
BAUD
Baud rate (in bits per second, bps)
System Oscillator clock frequency
Contents of the UBRRHn and UBRRLn Registers, (0-4095)
=
=
=
----------------------------------------- -
16 UBRRn
-------------------------------------- -
8 UBRRn
-------------------------------------- -
2 UBRRn
f
f
f
OSC
OSC
OSC
+
+
+
1
1
1
(1)
ATmega8U2/16U2/32U2
Equation for Calculating UBRR Value
UBRRn
UBRRn
UBRRn
=
=
=
----------------------- - 1
16BAUD
-------------------- 1
8BAUD
-------------------- 1
2BAUD
f
f
f
OSC
OSC
OSC
Table 18-9 on
151

Related parts for ATMEGA16U2-16AU