Raspberry Pi4 UART
------------------

The Pi4 has 4 additional UART (uart2-uart5) in addition to uart0/1 on the older Pi (only one of which can be used as they share GPIO).  
Functionally these are equivalent to the fully featured PL011 UART on uart0 and can optionally be configured with CTS/RTS.

These can be enabled (by editing `/boot/config.txt`), but this requires careful consideration of the impact on GPIO functionality.  
Activation of CTS/RTS functionality has additional impact

 - uart2 uses GPIO0/1 which are reserved and possibly impact on normal
   Raspbian functionality.
 - uart3 uses GPIO4/5 which is OK, although GPIO4 is commonly used for other purposes.
 - uart4 uses GPIO8/9 which are used for SPI0.
 - uart5 uses GPIO12/13 which conflict with the default pin allocation
   of gpio-fan (although this can be changed).

If additional UARTs are enabled they will appear as `/dev/AMAn`  
The first will be `/dev/AMA1` and increment if additional UART are enabled.

```
Name:   uart0
Info:   Change the pin usage of uart0
Load:   dtoverlay=uart0,<param>=<val>
Params: txd0_pin                GPIO pin for TXD0 (14, 32 or 36 - default 14)

        rxd0_pin                GPIO pin for RXD0 (15, 33 or 37 - default 15)

        pin_func                Alternative pin function - 4(Alt0) for 14&15,
                                7(Alt3) for 32&33, 6(Alt2) for 36&37


Name:   uart1
Info:   Change the pin usage of uart1
Load:   dtoverlay=uart1,<param>=<val>
Params: txd1_pin                GPIO pin for TXD1 (14, 32 or 40 - default 14)

        rxd1_pin                GPIO pin for RXD1 (15, 33 or 41 - default 15)


Name:   uart2
Info:   Enable uart 2 on GPIOs 0-3
Load:   dtoverlay=uart2,<param>
Params: ctsrts                  Enable CTS/RTS on GPIOs 2-3 (default off)


Name:   uart3
Info:   Enable uart 3 on GPIOs 4-7
Load:   dtoverlay=uart3,<param>
Params: ctsrts                  Enable CTS/RTS on GPIOs 6-7 (default off)


Name:   uart4
Info:   Enable uart 4 on GPIOs 8-11
Load:   dtoverlay=uart4,<param>
Params: ctsrts                  Enable CTS/RTS on GPIOs 10-11 (default off)


Name:   uart5
Info:   Enable uart 5 on GPIOs 12-15
Load:   dtoverlay=uart5,<param>
Params: ctsrts                  Enable CTS/RTS on GPIOs 14-15 (default off)
```

The following summarises the pin usage:-

```
		TXD	RXD	CTS	RTS		Board Pins
uart0	14	15				8	10
uart1	14	15				8	10
uart2	0	1	2	3		27	28	(I2C)
uart3	4	5	6	7		7	29
uart4	8	9	10	11		24	23 	(SPI0)
uart5	12	13	14	15		32	33	(gpio-fan)
```