<html><body><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div><br></div><div><br></div><hr id="zwchr" data-marker="__DIVIDER__"><div data-marker="__HEADERS__"><blockquote style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>From: </b>"Alex Carver" &lt;agcarver+ale@acarver.net&gt;<br><b>To: </b>ale@ale.org<br><b>Sent: </b>Thursday, November 19, 2015 10:26:11 AM<br><b>Subject: </b>Re: [ale] USB port identification<br></blockquote></div><div data-marker="__QUOTED_TEXT__"><blockquote style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><br><br>Write the udev rules to look at the vendor and product ID fields and<br>then perhaps the bus/sevice fields too. &nbsp;Use a unique combination of all<br>four fields to identify a single device. &nbsp;If the devices always come up<br>in the same order no matter which physical port they are using then all<br>four fields should stay unique during each boot.<br><br>Also double check what happens in the different configurations with<br>lsusb and see if there are any other udev rules in place already that<br>might be interfering.<br></blockquote><div><br></div><div>I have 500 USB-&gt;Serial adapters in boxes in my garage. &nbsp;Same vendor id and same product id.</div><div>They are not unique at all. &nbsp;All the same.</div><div><br data-mce-bogus="1"></div><div>Here is the problem. &nbsp;Look at the Ralink device</div><div><br data-mce-bogus="1"></div><div><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">[root@localhost]# lsusb</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 003: ID 0572:1340 Conexant Systems (Rockwell), Inc. </span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 002: ID 15d9:0a37 Trust International B.V. Mouse</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device <span style="background-color: rgb(255, 255, 0);">004</span>: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 003: ID 1a40:0101 Terminus Technology Inc. Hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 002: ID 8087:07e6 Intel Corp. </span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub</span><br></div><div><br data-mce-bogus="1"></div><div>Now, I'll unplug and plug it back in the SAME USB port.</div><div><br data-mce-bogus="1"></div><div><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">[root@localhost]# lsusb</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 003: ID 0572:1340 Conexant Systems (Rockwell), Inc. </span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 002: ID 15d9:0a37 Trust International B.V. Mouse</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 003 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device <span style="background-color: rgb(255, 255, 0);">005</span>: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 003: ID 1a40:0101 Terminus Technology Inc. Hub</span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 002: ID 8087:07e6 Intel Corp. </span><br><span style="font-family: 'courier new', courier, monaco, monospace, sans-serif;" data-mce-style="font-family: 'courier new', courier, monaco, monospace, sans-serif;">Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub</span><br></div><div><br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div></div></div></body></html>