
On 10/31/19 2:25 AM, Jim Ruxton via talk wrote:
I have a device plugged into an active USB extender that usually shows up as /dev/ttyUSB0 when I first plug it in (occasionally it will show up as /dev/ttyUSB1 when first plugging it in) . If it is /dev/ttyUSB0 when I unplug it and plug it back in it occasionally changes to /dev/ttyUSB1 . Is there a way that I can always have it show up as /dev/ttyUSB0 . I'm not sure why /dev/ttyUSB0 isn't being released and restarted after unplugging and replugging it. If I look in /dev it does disappear as /dev/ttyUSB0 from there when I unplug it but like I said it reappears as /dev/ttyUSB1? I am on Ubuntu 18.04.3 LTS .
Thanks for any pointers.
Thinking on this some more. You could try using /dev/serial/by-path or /dev/serial/by-id "ls /dev/serial/by-path/" -> pci-0000:00:12.2-usb-0:3.5:1.0-port0 "ls /dev/serial/by-id" -> usb-Prolific_Technology_Inc._USB-Serial_Controller-if00-port0 These should stay device and connection tree uinque -- Alvin Starr || land: (647)478-6285 Netvel Inc. || Cell: (416)806-0133 alvin@netvel.net ||