4
votes

I get this error message when i try to upload code to my arduino. Does anyone know what is going on?

I have installed the proper drivers and it works fine. My port appears on the menu and it is the corresponent to the device.

bless

7

7 Answers

1
votes

Common error, here is the solution:

1 - Unplug the Arduino

2 - Upload code with no Arduino connected to PC

3 - Reconnect Arduino

4 - Upload code to the Arduino

Good luck!

1
votes

If you are on Linux, just set current user to belong to "dialout" group which is the one who members are allowed to access ports.

Run following:

sudo adduser yourUserName dialout

then relog to take effect

(Ubuntu 18.04)

0
votes

USB may need CH340 driver. Some Arduinos use the CH340 controller Find and install the CH34X_Driver_V3.4_Windows.zip

0
votes

click right on this computer, go to management, device manager, com, find the port of Arduino, then go to tools and in port select the com

0
votes

I had the COM3 error too and this fixed it.

Open the Arduino application as Administrator (Shift+Rightclick the app, 'Run as administrator').
I still had to upload without the Arduino connected, then connect and upload.

0
votes

I had the same problem:

  1. If you are using VS Code with Platform IO and you spam Serial Monitor with many message too fast, then when trying again to upload it will give you the above error. One way to solve it is to press the reset button on your board and immedietly after that to press upload in VS Code. Just don't spam the Serial Monitor too fast, when using VS Code with Platform IO and uploading while monitoring it.

  2. If you are using CLion with Platform IO and you have opened Serial Monitoring via pio device monitor then you must close it and then upload, because it is using the port.

0
votes

From terminal:

ls -l /dev/ttyUSB*
# or:
ls -l /dev/ttyACM*

Get the groupname from the result:

crw-rw---- 1 root uucp 188, 0  5 apr 23.01 ttyUSB0
# or:
crw-rw---- 1 root dialout 188, 0  5 apr 23.01 ttyACM0

Add your username to the group:

usermod -a -G uucp username
# or:
usermod -a -G dialout username

Log out and in again for this change to take effect.

Source: https://playground.arduino.cc/Linux/All/#Permission