Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Startup script which initializes the serial ports for the cc3200 under Ubuntu

3 views
Skip to first unread message

Dave Hylands

unread,
Oct 26, 2016, 7:20:08 PM10/26/16
to mozilla-de...@lists.mozilla.org
I created a startup script called cc3200-serial.sh which will install itself into the /etc/init.d so that your FTDI serial ports will be insitialized automatically on every boot.


Once you've run the script you should see /dev/ttyUSB0 and /dev/ttyUSB1

I tested this under Ubuntu 16.04 LTS.

Immediately upon bootup, the permissions show up as:

crw------- 1 root root 188, 0 Oct 26 16:17 /dev/ttyUSB0
crw------- 1 root root 188, 1 Oct 26 16:17 /dev/ttyUSB1

and then after about 30 seconds or so, the permissions change to:

crw-rw-rw- 1 root dialout 188, 0 Oct 26 16:18 /dev/ttyUSB0
crw-rw-rw- 1 root dialout 188, 1 Oct 26 16:18 /dev/ttyUSB1

If you're not seeing the permissions change, let me know, and I can make some more changes.

Dave Hylands

Thomas Zimmermann

unread,
Oct 27, 2016, 4:19:04 AM10/27/16
to Dave Hylands, mozilla-de...@lists.mozilla.org
I made a udev rule from the info I found on the Internet. It's the same
as what your script creates. But I use 660 permissions and added myself
to the dialout group. I don't think I've ever seen this delay between
dev file creation and permission assignment.
> _______________________________________________
> mozilla-dev-sensorweb mailing list
> mozilla-de...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/mozilla-dev-sensorweb

Dave Hylands

unread,
Oct 27, 2016, 4:00:03 PM10/27/16
to Thomas Zimmermann, mozilla-de...@lists.mozilla.org
Yeah - I did 2 versions of the script. The first one did used /etc/init.d and it was the one with the delay.

The second version uses udev, and the delay is now between boot time and when udev gets around to creating /dev/ttyUSB0/1. On my laptop, I can get logged into the machine and have a terminal window up about 30 seconds before /dev/ttyUSB0/1 exist.

I decided to go with the pure udev version since I think it will work on more variants of linux. It is also just using the udev script presented. I normally use 0666 because adding yourself to the dialout group requires a logoff/logon, and is one more step getting into the way of using the serial port. For advanced users, I'd probably go with 0660 and dialout. But for many users, its just way simpler to use 0666.

0 new messages