Closed dzfranklin closed 2 years ago
The /dev/serial/...
name is actually good because it'll be constant for a specific device no matter when or where it's plugged in but it is long. Another way is to create a udev rule that creates a constant symlink in /dev like so...
/etc/udev/rules.d/50-gps.rules
SUBSYSTEM=="tty", ATTRS{serial}=="UBXF9P01", MODE="0666", SYMLINK+="ttyUSB_UBF9001"
That would make a USB device with serial number UBXF9P01
always show up as /dev/ttyUSB_UBF9001
no matter where or when it's plugged in. Could also make the name /dev/gps-UBF9001
or anything that's convenient to you.
Anyway, I'll at least see if I can test the file name length and if it doesn't fit, maybe use the /dev/ttyUSB...
symlink or just truncate the name to fit. Thanks for the report.
This is caused by the device name being to long. I didn't know the normal way to refer to a device would be something like
/dev/ttyUSB0
.I don't think this is worth fixing. I'm filing and immediately closing this issue in the hope this will save someone else what for me was an embarrassing amount of debugging.