I am using arduino-ide
2.0.0-beta.7(CLI Version:0.18.3 alpha) on Manjaro Linux and I get this error when uploading sketch to my Arduino Micro:
avrdude: ser_open(): can't open device "/dev/ttyACM0": Permission denied Upload error: Error: 2 UNKNOWN: uploading error: uploading error: exit status 1
I checked other questions and tried:
sudo groupadd dialout
sudo gpasswd -a $USER dialout
sudo chmod a+rw /dev/ttyACM0
sudo usermod -a -G dialout $USER
sudo chown root:dialout -R /dev/
ls -l /dev/ttyACM0 #can see the root:dialout
But when I logout and get again after ls -l /dev/ttyACM0
:
crw-rw-rw- 1 root uucp 166, 0 6月 13 17:06 /dev/ttyACM0
So I cannot upload the sketch. Note: I can upload sketches using sudo arduino-ide --no-sandbox
, but I want to upload them from the user
account.
What else can I try?
1 Answer 1
Instead of:
sudo usermod -a -G dialout $USER
I had to run:
sudo usermod -a -G uucp $USER
Thanks to @Juraj I realized that. Thanks @Juraj.
Explore related questions
See similar questions with these tags.
sudo usermod -a -G uucp $USER
instead ofsudo usermod -a -G dialout $USER
. Thanks.