Extra UART's on my RPi4

Raspberry Pi 4 with extra UARTs

The Raspberry Pi 4 introduced a number of extra UART’s for serial connections to various other systems. This short note provides the configuration I use as standard with RPi’s that need extra Serial Ports.

/boot/firmware/config.txt or used to be /boot/config.txt contents:

# For more options and information see
# http://rptl.io/configtxt
# Some settings may impact device functionality. See link above for details

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on   # used by bme280 and the OLED display
#dtparam=i2s=on
#dtparam=spi=on

# Enable audio (loads snd_bcm2835)
dtparam=audio=off      # change to off as it's headless so don't need it.

# Additional overlays and parameters are documented
# /boot/firmware/overlays/README

# Automatically load overlays for detected cameras
camera_auto_detect=1

# Automatically load overlays for detected DSI displays
display_auto_detect=1

# Automatically load initramfs files, if found
auto_initramfs=1

# Enable DRM VC4 V3D driver
dtoverlay=vc4-kms-v3d
max_framebuffers=2

# Don't have the firmware create an initial video= setting in cmdline.txt.
# Use the kernel's default instead.
disable_fw_kms_setup=1

# Run in 64-bit mode
arm_64bit=1

# Disable compensation for displays with overscan
disable_overscan=1

# Run as fast as firmware / board allows
arm_boost=1

# removed cm4 section as it's only going to be RPi4B's

[all]

# UART settings from here to bottom of file.

# apply any/all overlays defined before this point
dtoverlay=

# enable uart's
enable_uart=1

# enable uart3 with ctsrts. CTS used to program the ATMega328 using Arduino method
dtoverlay=uart3,ctsrts

# enable uart4 and uart5. No hardware flow control needed. No other settings found.
dtoverlay=uart4

Author photo
Publication date:
Author: Trevor

Leave a Reply