Armate Posted February 21, 2023 Share Posted February 21, 2023 I have Rock Pi S V13, that has 4 UART ports. I'm already connecting to the board via serial console on /dev/ttyS0. How can I find out what are the other ports assignments/paths? I have tried to use a Python script to detect the output by using an FTDI to USB board with no luck (the voltage and baudrate are correct). The Python script taken from manual: import serial import time # I've tried /dev/ttyS2 and /dev/ttyS4 ser = serial.Serial(port='/dev/ttyS4', baudrate=115200, timeout=0.1) print(ser.name) try: while True: ser.write(b'hello') time.sleep(0.5) except KeyboardInterrupt: ser.close() Running Quote ls /sys/class/tty/*/device/driver outputs Quote /sys/class/tty/ttyS0/device/driver: bind ff0a0000.serial ff0c0000.serial ff0e0000.serial uevent unbind /sys/class/tty/ttyS1/device/driver: bind serial8250 uevent unbind /sys/class/tty/ttyS2/device/driver: bind ff0a0000.serial ff0c0000.serial ff0e0000.serial uevent unbind /sys/class/tty/ttyS3/device/driver: bind serial8250 uevent unbind /sys/class/tty/ttyS4/device/driver: bind ff0a0000.serial ff0c0000.serial ff0e0000.serial uevent unbind /sys/class/tty/ttyS5/device/driver: bind serial8250 uevent unbind /sys/class/tty/ttyS6/device/driver: bind serial8250 uevent unbind /sys/class/tty/ttyS7/device/driver: bind serial8250 uevent unbind and Quote ls -l /dev/tty* | grep 'dialout' outputs Quote crw-rw---- 1 root dialout 4, 65 Dec 23 11:44 /dev/ttyS1 crw-rw---- 1 root dialout 4, 66 Dec 23 11:44 /dev/ttyS2 crw-rw---- 1 root dialout 4, 67 Dec 23 11:44 /dev/ttyS3 crw-rw---- 1 root dialout 4, 68 Dec 23 11:44 /dev/ttyS4 crw-rw---- 1 root dialout 4, 69 Dec 23 11:44 /dev/ttyS5 crw-rw---- 1 root dialout 4, 70 Dec 23 11:44 /dev/ttyS6 crw-rw---- 1 root dialout 4, 71 Dec 23 11:44 /dev/ttyS7 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.