Hello, as of 2025 what is the current method to enable UART port on a Beaglebone Black? There seems to be a lot of outdated information on this forum which is not working for me.
- Do you need it to enable login via UART?
- Or to enable using UART for data transfer?
To answer the question 1 I wrote, UART0 (/dev/ttyS0) seems to be enabled by default, but I don’t know if there is a getty listening there. Systemd is running and getty target (which usually refers to login prompt, I guess) is active, but I’m not currently aware how it is set up. I could test hooking up some cables to the serial debug port (UART0), to see what it’s doing.
To answer the question 2 I wrote, I’ve been using other Beaglebone Black UARTs (/dev/ttyS1…/dev/ttyS5 which correspond to UART1…UART5) for data transfer. Running BalenaOS 6.0.32 now.
I separately add these lines on each Balena device (“host OS”) to /mnt/boot/uEnv.txt:
enable_uboot_overlays=1
uboot_overlay_addr0=/boot/overlays/BB-UART1-00A0.dtbo
uboot_overlay_addr1=/boot/overlays/BB-UART2-00A0.dtbo
uboot_overlay_addr2=/boot/overlays/BB-UART3-00A0.dtbo
uboot_overlay_addr3=/boot/overlays/BB-UART4-00A0.dtbo
uboot_overlay_addr4=/boot/overlays/BB-UART5-00A0.dtbo
and reboot.
Note there is only TX (no RX) on UART3.
Using overlays, you can also enable using I2C ports, RTCs etc. The pre-compiled overlays are in “host OS” under /boot/overlays (not /mnt/boot). I’ve used RTCs and I2C sensors with Balena, it should work.
Hi, we figured it out in the end, but to me this doesn’t seem like something I can roll out to a fleet of these devices, if i need to manually edit a boot file on each one to get it to read the /ttys01 device … I was hoping it could be done using device configuration variables or dockerfile