I too have been stuck for the past few months attempting to access the UART pins via serial connection. I am running Debian Bullseye. My problem is that I cannot manage to identify a device node in /dev/ associated with main_uart5
, which is the device tree node corresponding to the mikrobus UART pins.
My initial understanding was that I had to use an overlay to “release” the mikrobus device tree settings and restoring the “native” UART pin settings, referring to the latest source located at BeagleBoard-DeviceTrees
In /opt/source/dtb-5.10-ti/src/arm64/overlays
I created a new .dts file drawing from the aforementioned source file. The contents are as follow:
/* k3-am625-beagleplay-release-mikrobus-set-uart-default.dts */
/dts-v1/;
/plugin/;&{/chosen} {
overlays {
k3-am625-beagleplay-release-mikrobus-set-uart-default = TIMESTAMP;
};
};
&mikrobus0 {
status = “disabled”;
};
&main_uart5 {
status = “okay”;
pinctrl-names = “default”;
pinctrl-0 = <&mikrobus_uart_pins_default>;
};
I then compiled and installed the overlay using the method described in this forum post Finally I added a line to load the overlay in /boot/firmware/extlinux/extlinux.conf:
fdtoverlays /overlays/k3-am625-beagleplay-release-mikrobus-set-uart-default.dtbo
… and rebooted my Beagleplay. Finally, I noted that the overlay was successfully loaded by running ls /proc/device-tree/chosen/overlays/
@Lars71dk, I see from your solution (using Yocto) that you had success by modifying u-boot options, inserting tty1 and ttyS2 as console arguments. I am, as yet, uneasy about modifying my extlinux.conf without first understanding what is preventing uart5 from being linked. My dmesg output shows consoles enabled by default on tty0 and ttyS2. Alas, similar to @ezrobot above, my dmesg
is also showing that ttyS3 and ttyS4 are created before apparently being reclaimed as serial0 and serial1:
[ 1.755656] 2850000.serial: ttyS3 at MMIO 0x2850000 (irq = 30, base_baud = 3000000) is a 8250
[ 1.755728] serial serial0: tty port ttyS3 registered
[ 1.756708] 2860000.serial: ttyS4 at MMIO 0x2860000 (irq = 31, base_baud = 3000000) is a 8250
[ 1.756828] serial serial1: tty port ttyS4 registered
I can only assume that one of those two ttys attaches to uart5 but I’m still uncertain
Any help or suggestions would be most appreciated!
UPDATE:
Following up with an update as I have made progress on this since yesterday. Drawing from @Lars71dk above-posted solution, I edited /opt/source/dtb-5.10-ti/src/arm64/k3-am625-beagleplay.dts by commenting-out the line force-empty-serdev-controller
under &main_uart5
, compiling and installing the new dtb. Now a device node is finally appearing at both /dev/ttyS3 and /dev/play/mikrobus/uart. Tested both of these device nodes by running a serial connection using mikrobus UART pins and it works!