All peripherals must have their functions allocated by the crossbar in order for them to be available at the pins of the device. In many devices there are no dedicated pins for TX and RX; however, some TX and RX signals are allocated by the crossbar to port 0 pin 4 for Tx and port 0 pin 5 for Rx for all cases. The XBRx registers define what peripherals get assigned to I/O through the crossbar. In addition, the I/O pins need to be configured appropriately for the direction of the signal mapped to the pin. For example, the Tx signal requires the pin to be configured as a push pull output, whereas the Rx signal requires the pin to be configured as an input. These can be configured through the PMDOUT register. A suitable timer needs to be programmed to generate the baud rate. Configuration of the timer will be covered in later slides. The SCON0 register is used to select the serial port operation mode and enable/disable UART reception. Then the user can enable the UART interrupts and set the priorities (if desired).