Find the answer to your Linux question:
Results 1 to 4 of 4
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    USB port conflict

    Hi all,

    I am using FC15. I have 2 usb devices both detected as CDC-ACM. The port to which devices are connected always keep changing.
    Initially port to which device one connected is showing ttyACM0 and the other showing ttyACM1. When I removed these devices and reinsert them now I insert device two first so the ttyACM0 is got assigned to this device and device one got ttyACM1.
    I want to keep port number same every time. Please suggest me what I need to do, so that every time my device one will get port ttyACM0 and device two ttyACM1 irrespective of anything.

  2. #2

    You should be able to use udev rules to do this. The udevadm command can be used to interrogate the device and hopefully turn up some useful info (like serial numbers or other unique identifiers) which you can in turn use to craft your udev rules.

    First find the serial character devices in the /sys directory, e.g.:

    find /sys/|grep ttyACM[01]
    Say it turns up this file:
    Now run udevadm like this to get info on it:
    udevadm info --query=all --path=/sys/class/tty/ttyACM0
    You should get back a bunch of info. Now write your udev rule. Where it goes, and exactly which attributes you can use depends on your distro and version of udev. See this document for starters on writing udev rules, it has been around a while, though is likely outdated now:

    You can hopefully google for a tutorial on writing udev rules specifically for your distro.

  3. #3

    Thank you very much. This helped me to solve my problem.

    Is it possible to add serial device in same way to udev rules.
    Please assist.
    Last edited by vishalp; 11-28-2012 at 09:04 AM.

  4. $spacer_open
  5. #4
    Quote Originally Posted by vishalp View Post
    Is it possible to add serial device in same way to udev rules.
    Do you mean the serial ports on the motherboard, or on a PCI card? I don't see why not, but I guess it depends on whether there is unique identifying attributes returned by udevadm.

    If you got it to work using your ACM devices, can you not apply the same logic to the serial devices?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts