04-11-2022, 09:14 PM
Hi, I am working with getting some UART code running on the Alchitry AU and realized I had a question. Which of the two /dev/ttyUSB? ports is which. In the schematic JTAG seems to be port A and UART on port B, but would that necessarily give the expected result of /dev/ttyUSB0 is the JTAG and /dev/ttyUSB1?
PySerial just labels them both "Alchitry - Au"
I suspect it's arbitrary which is which, just whichever the kernel saw first, but I was wondering if anyone had an easy way to read them and be sure.
PySerial just labels them both "Alchitry - Au"
Code:
>>> from serial.tools import list_ports
>>> for element in list_ports.comports(): print(element)
...
/dev/ttyUSB1 - Alchitry Au - Alchitry Au
/dev/ttyUSB0 - Alchitry Au - Alchitry Au
>>>
I suspect it's arbitrary which is which, just whichever the kernel saw first, but I was wondering if anyone had an easy way to read them and be sure.