What is this?
You ever spend way too much time troubleshooting an issue only to find yourself in the same situation a month later when you've forgotten everything? Well that's my life. If only I had written down all the steps I through so that I could reference it later. "Eh, I won't forget this time," I say as I'm looking up a process I repeat the same thing for the 4th time.
I could of course record my troubleshooting steps in a private text document, but that's boring and prone to being misplaced. Why not write them down publicly to be ridiculed by the masses? So that's what I did. I hope you find my ramblings useful.
Configure UART for Ubuntu Server 20.04 on Raspberry Pi 3 B+
If you want to transfer data over the onboard UART connection, you will need to disable the serial console which is enabled by default on the Raspberry Pi version of Ubuntu Server 20.04. Otherwise, the serial device will already be in use, meaning you won't be able to use it for other data transfer.
The serial console is configured by the Linux kernel during boot. The configuration can be changed by modifying the the cmdline.txt file in the boot partition. Note: in previous versions of Ubuntu Server for the Raspberry Pi was located in the /boot directory but has since been move to /boot/firmware. Open /boot/firmware/cmdline.txt file, and remove console=serial0,115200 and console=tty1. If you are editing this file directory on the Raspberry Pi (as opposed to modifying the file on another computer), you will need to reboot for the settings to take effect. For more information on the kernel configuration, check out The Kernel Command Line.
To test everything out, you can connect the Raspberry Pi to another computer with a 3.3 V FTDI breakout board. On the computer, open a serial connection with the breakout board using screen /dev/ttyUSB1 115200. Note: the device file may be different. On the Raspberry Pi, open a serial connection with the onboard serial device with screen /dev/ttyS0 115200. Now you should be able to type in one screen window and see the output on the other.