atmega103 ATMEL Corporation, atmega103 Datasheet - Page 69

no-image

atmega103

Manufacturer Part Number
atmega103
Description
Atmega103 8-bit With 128k Bytes Of In-system Programmable Flash
Manufacturer
ATMEL Corporation
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
atmega103-6AC
Manufacturer:
ATMEL
Quantity:
1
Part Number:
atmega103-6AI
Manufacturer:
ATMEL
Quantity:
586
Part Number:
atmega103-6AI
Manufacturer:
Atmel
Quantity:
10 000
ATmega103(L)
Figure 43. Sampling Received Data
RXD
START BIT
D0
D1
D2
D3
D4
D5
D6
D7
STOP BIT
RECEIVER
SAMPLING
When the stop bit enters the Receiver, the majority of the three samples must be one to
accept the stop bit. If two or more samples are logical “0”s, the Framing Error (FE) Flag
in the UART Status Register (USR) is set when the received byte is transferred to UDR.
Before reading the UDR Register, the user should always check the FE bit to detect
Framing Errors. FE is cleared when UDR is read.
Whether or not a valid stop bit is detected at the end of a character reception cycle, the
data is transferred to UDR and the RXC Flag in USR is set. UDR is in fact two physically
separate registers, one for transmitted data and one for received data. When UDR is
read, the Receive Data Register is accessed, and when UDR is written, the Transmit
Data Register is accessed. If 9-bit data word is selected (the CHR9 bit in the UART Con-
trol Register, UCR is set), the RXB8 bit in UCR is loaded with bit 9 in the Transmit Shift
Register when data is transferred to UDR.
If, after having received a character, the UDR Register has not been accessed since the
last receive, the OverRun (OR) flag in USR is set. This means that the new data trans-
ferred to the Shift Register could not be transferred to UDR and is lost. The OR bit is
buffered, and is available when the valid data byte in UDR has been read. The user
should always check the OR after reading from the UDR Register in order to detect any
OverRuns if the baud rate is high or CPU load is high.
When the RXEN bit in the UCR Register is cleared (zero), the Receiver is disabled. This
means that the PE0 pin can be used as a general I/O pin. When RXEN is set, the UART
Receiver will be connected to PE0, which is forced to be an input pin regardless of the
setting of the DDE0 bit in DDRE. When PE0 is forced to input by the UART, the
PORTE0 bit can still be used to control the pull-up resistor on the pin.
When the CHR9 bit in the UCR Register is set, transmitted and received characters are
9 bits long plus start and stop bits. The 9th data bit to be transmitted is the TXB8 bit in
UCR Register. This bit must be set to the wanted value before a transmission is initated
by writing to the UDR Register.
69
0945I–AVR–02/07

Related parts for atmega103