I need 9 bit UART data on an Arduino Uno and so I have to do some manual setup of the Arduino UART.
Basically, I don't understand this line of example code (from the datasheet), it is meant to enable a UART Tx and Rx pin on the Arduino, which done in simple and easy to understand machine language just means loading an immediate value to UCSR0B
(USART Control and Status Register B) in a way that the RXE (Recieve Enable) bit, and TXE (Transmission Enable) bit are both high. In other words, load 00011000
into USCR0B
.
Here's the example C code from the datasheet:
USCR0B = (1 << RXE) | (1 << TXE);