AVR serial communications
From Just in Time
Notes on getting serial communications to work on AVR.
Registers
- UCSRB
- (USART Control and Status Register B) In this register, set RXEN to enable serial reception and TXEN to enable serial transmission.
- UBRR
- (USART Baud Rate Register) Sets the baud rate. The baud rate is fosc/(UBBR+1) divided by 2, 8 (U2X = 1) or 16 (U2X = 0). U2X is located in UCSRA.