ubuntu12.04使用USB转串口时出现权限不够问题,如下

Unable to open serial port /dev/ttyUSB0

权限不够

解决办法:

通过增加udev规则来实现。步骤如下:
创建文件/etc/udev/rules.d/70-ttyusb.rules
在文件内增加一行
KERNEL=="ttyUSB[0-9]*", MODE="0666"
重新插入USB转串口设备,普通用户就有权限访问了。

70-ttyusb.rules文件还有另一种写法,先用lsusb查看USB转串口芯片的idVendor和idProduct
#lsusb
显示结果中有这么一行
Bus 005 Device 007: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
ID 0403:6001表示idVendor=0403,idProduct=6001
70-ttyusb.rules的内容如下:
SUBSYSTEM=="tty", ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6001",MODE="0666"
重新插入USB转串口设备,普通用户同样可以访问了

Unable to open serial port /dev/ttyUSB0的更多相关文章

  1. ROS 进阶学习笔记(12) - Communication with ROS through USART Serial Port

    Communication with ROS through USART Serial Port We always need to communicate with ROS through seri ...

  2. Serial Port Programming on Linux(转载)

    This is a tutorial on how to program the Serial Ports on your Linux box.Serial Ports are nice little ...

  3. select/poll/epoll on serial port

    In this article, I will use three asynchronous conferencing--select, poll and epoll on serial port t ...

  4. Connecting to a Remote Serial Port over TCP/IP

    https://www.acmesystems.it/socat This article illustrates how to realize a lan to serial gateway Rem ...

  5. [原]OS X 10.9 Mavericks - Virtual Serial Port Issues

    If want to do iOS kernel debugging on A4 device, first you should install Virtual COM port (VCP) dri ...

  6. Non-standard serial port baud rate setting

    ////combuad_recv.cpp #include <stdio.h> /*标准输入输出定义*/ #include <stdlib.h> /*标准函数库定义*/ #in ...

  7. 记一次使用git报错,解决Unable to negotiate with **** port 22: no matching host key type found. Their offer: ssh-rsa

    windows电脑重装系统,去官网下载了最新的git安装,一路next下来,打开bash按老路子设置,生成公钥 git config --global user.name "yourname ...

  8. IntelliJ运行下载的Servlet时报错 Error running Tomcat 8.5.8: Unable to open debugger port (127.0.0.1:49551): java.net.SocketException

    学习Java Servlet时,从Wrox上下载了示例代码,准备run/debug时发现以下错误: Error running Tomcat 8.5.8: Unable to open debugge ...

  9. Serial Port Programming using Win32 API(转载)

    In this tutorial we will learn How to communicate with an external device like a microcontroller boa ...

随机推荐

  1. EV电池指标及特点

    在电池的大家族中,蓄电池的种类是最多的,共同的特点是可以经历多次充电.放电循环,反复使用,这也正是蓄电池作为电动汽车动力源的基础.当然,并不是所有的蓄电池都适合应用于电动汽车,从全球新能源汽车的发展来 ...

  2. ContentProvider 使用示例(转载)

    ContentProvider 使用示例(转载) 当数据需要在应用程序间共享时,我们就可以利用ContentProvider为数据定义一个URI.之后其他应用程序对数据进行查询或者修改时,只需要从当前 ...

  3. EF LEFT JON 关联查找

    var query = (from a in context.OQC_INSPECTION_SAMPLE.Where(expression).Where(a => context.OQC_INS ...

  4. [转]使用 Minidumps 和 Visual Studio .NET 进行崩溃后调试

    本文关键字:Minidumps, Windows, SEH, VisualC, .NET 摘要 本文讲述了 minidumps 是怎样工作的.当你的程序崩溃的时候应该如何生成它们.以及如何在 Visu ...

  5. SoPC/Qsys杂谈

    1. 如果你想把Reset Vector放在EPCS Controller里面,记得将CPU core的Instruction Master和Data Master都连接到EPCS Controlle ...

  6. Python 通过pickle标准库加载和保存数据对象

    import pickle with open('mydata.pickle','wb') as mysavedata: pickle.dump([1,2,'three'], mysavedata) ...

  7. 在 Perl 中使用 Getopt::Long 模块来接收用户命令行参数

    我们在linux常常用到一个程序需要加入参数,现在了解一下 perl 中的有关控制参数的模块 Getopt::Long ,比直接使用 @ARGV 的数组强大多了.我想大家知道在 Linux 中有的参数 ...

  8. 黄聪:VPS实现自动定时备份网站数据以及Mysql数据库到百度云同步盘

    建站多了,备份成了头疼的问题,因为你不知道你的VPS什么时候会宕机或者服务商跑路,一旦网站数据丢失,那么相当于前功尽弃了,所以自己研究出了一套自动备份的方法. 需要的东西: 1.一个VPS(虚拟空间没 ...

  9. Android Gradle实用技巧——多渠道打包

    友盟有很多不错的功能,例如渠道统计等. 想要做渠道统计,有一个要求就是要在manifest文件中添加各个渠道的配置.只有一两个渠道还好说,但是渠道多了的话,手动修改然后打包简直是噩梦. 幸好现在And ...

  10. ActionScript 3.0 编程精髓 示例源码下载

    根据书籍介绍(http://product.china-pub.com/38852#qy)的指引,找到了下载地址:http://moock.org/eas3/examples/