Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Arduino Nano - "avrdude: ser_open():system can't open device "\\.\COM1": the system cannot find the file specified"

Tags:

arduino

I am working with an Arduino Nano.

avrdude: ser_open(): system can't open device "\.\COM1": the system cannot find the file specified

This error appears just after uploading the program on the Arduino board. I have checked my port in my device manager. It says COM11 and in the Arduino software as well COM11 is selected.

I have the Arduino Nano board selected in my Arduino software. Also, there mustn't be any specification error while downloading the software file. Is there anything that I am missing?

like image 829
user4018137 Avatar asked Sep 08 '14 06:09

user4018137


3 Answers

This is how I solved the problem. In Device Manager you will find the Arduino COM port.

Enter image description here

Go to the Advanced properties of the port

Enter image description here

Set the COM port number to COM1.

Enter image description here

Then replug the USB.

like image 117
Andre Lombaard Avatar answered Oct 04 '22 20:10

Andre Lombaard


Instead of changing the COM port in Device manager, if you're using the Arduino software, I had to set the port in Tools > Port menu.

enter image description here

like image 30
Chuck D Avatar answered Oct 04 '22 19:10

Chuck D


My issue was due to what physical USB female port I plugged the Arduino cable into on my D-Link DUB-H7 (USB hub) on Windows 10. I had my Arduino plugged into one of the two ports way on the right (in the image below). The USB cable fit, and it powers the Arduino fine, but the Arduino wasn't seeing the port for some reason.

enter image description here

Windows does not recognize these two ports. Any of the other ports are fair game. In my case, the Tools > Port menu was grayed out. In this scenario, the "Ports" section in the object explorer was hidden. So to show the hidden devices, I chose View > show hidden. COM1 was what showed up originally. When I changed it to COM3, it didn't work.

There are many places where the COM port can be configured.

Windows > Control Panel > Device Manager > Ports > right click Arduino > Properties > Port Settings > Advanced > COM Port Number: [choose port]

Windows > Start Menu > Arduino > Tools > Ports > [choose port]

Windows > Start Menu > Arduino > File > Preferences > @ very bottom, there is a label named "More preferences can be edited directly in the file".

C:\Users{user name}\AppData\Local\Arduino15\preferences.txt

target_package = arduino
target_platform = avr
board = uno
software=ARDUINO
# Warn when data segment uses greater than this percentage
build.warn_data_percentage = 75

programmer = arduino:avrispmkii

upload.using = bootloader
upload.verify = true

serial.port=COM3
serial.databits=8
serial.stopbits=1
serial.parity=N
serial.debug_rate=9600

# I18 Preferences

# default chosen language (none for none)
editor.languages.current = 

The user preferences.txt overrides this one:

C:\Users{user name}\Desktop\avrdude.conf

... search for "com" ... "com1" is the default

like image 32
MacGyver Avatar answered Oct 04 '22 21:10

MacGyver