avrdude:ser_open():无法打开设备"/dev/ttyACM0&":设备或资源繁忙 [英] avrdude: ser_open(): can't open device "/dev/ttyACM0": Device or resource busy
问题描述
我是Linux Mint用户.我正在处理Arduino Yun.正在编译Arduino程序.之后我上传到Arduino Yun.然后我得到这些错误.你能帮我吗?
I am Linux Mint user.I am dealing with Arduino Yun.I am compiling Arduino program.After that I am uploading to Arduino Yun.Then I get these error.Can you help me?
推荐答案
you first need to make sure you have the correct read/write rights, as described here, esentially enter following commands:
$ sudo adduser <username> dialout
$ sudo chmod a+rw /dev/ttyACM0
'/dev/ttyACM0'是您的arduino连接到的端口,应该在根目录的/dev文件夹中列出.
the '/dev/ttyACM0' is the port your arduino is connected to, it should be listed in the /dev folder of your root.
秒::在确定arduino连接到哪个端口并为该端口设置了正确的权限后,需要运行以下命令.我不确定它是做什么的,也不确定是否确实需要它,但是它使上传在几次情况下对我来说都是有效的
second: after you have identified which port the arduino is connected to and you have set the correct rights for this port, you need to run following command. I am not sure what it does, I am not sure if it's really needed, but it made the uploads work for me on several occasions
$ sudo udevadm trigger
and third, you will find the upload sometimes a challenge of timing and luck. Keep pressing the reset (sometimes twice very consecutively) and meanwhile press the upload button of your arduino sketch. At certain moment, it will work. I had more luck when constantly changing small pieces in the code, so when I pushed 'upload', it had to compile the code first.
https://www.arduino.cc/zh-CN/Guide/Troubleshooting#upload
在某些计算机上,您可能需要按重置"按钮
on some computers, you may need to push teh reset button
我从来没有碰过引导加载程序,也从未碰过ICSP引脚之类的东西(幸运的是)
I have never messed with the bootloader, nor with ICSP pins and such (luckily)
Also have a look on the Arduino forum or on the link provide by yourself
这篇关于avrdude:ser_open():无法打开设备"/dev/ttyACM0&":设备或资源繁忙的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!