How can I create a persistent name for a device on openwrt?

3

When I connect an Arduino to my openwrt router it is assigned a device /dev/ttyUSB<n> where n=0,1,2... typically /dev/ttyUSB0. The assignment clashes with my 3G mobile dongle which also gets /dev/ttyUSB<x> (a different number) but this leaves the ppp driver trying to talk to the Arduino.

I would like to create specific aliases /dev/ttyArduino and /dev/ttyMobile that I can then use in my configuration.

Under most linuxes I could do this by creating a udev rule, but openwrt (Barrier Breaker 14.07) runs something other than udev so does not have /etc/udev/rules.d.

What is the correct way to create persistent aliases for devices under openwrt?

meesern

Posted 2015-07-22T16:41:44.520

Reputation: 131

Answers

0

One alternative is to use hotplug to create symlinks to your devices.

https://wiki.openwrt.org/doc/techref/hotplug

Marcelo Cerri

Posted 2015-07-22T16:41:44.520

Reputation: 1

1You should explain how to do so in your answer and take important info from your link and put them into your answer. Otherwise, it would've been more suitable as a comment (which you do not have enough reputation to do) – Insane – 2015-11-12T02:51:17.513