Unable to open serial port/dev/ttyusb0

Source: Internet
Author: User

Ubuntu12.04 insufficient permissions when using USB to serial port, as shown below:

Unable to open serial port/dev/ttyusb0

Insufficient Permissions

 

Solution:

Add udev rules. The procedure is as follows:
Create a file/etc/udev/rules. d/70-ttyusb.rules
Add a line to the file
Kernel = "ttyusb [0-9] *", mode = "0666"
After you re-insert the USB to the serial port device, the common user has the permission to access the device.

 

The 70-ttyusb.rules file also has another method. Use lsusb to check the idvendor and idproduct of the USB-to-serial chip.
# Lsusb
This row is displayed in the result.
Bus 005 device 007: Id 0403: 6001 future technology devices International, Ltd ftbench USB-serial (UART) IC
Id 0403: 6001 indicates idvendor = 0403, idproduct = 6001
The content of 70-ttyusb.rules is as follows:
Subsystem = "tty", attrs {idvendor} = "0403", attrs {idproduct} = "6001", mode = "0666"
Re-insert the USB-to-serial port device, which can be accessed by common users.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.