Arduino COM port doesn't work - serial-port

I bought an Arduino Uno recently. After getting the necessary cables, I decided to upload an example to the chip.
Instead of seeing that Blink, I received an error like processing.app.SerialException: Serial port 'COM1' not found. Did you select the right one from the Tools > Serial Port menu?
Yes, I tried that. But even Serial Port Monitor doesn't seem opening. Then again, I get some exception that isn't worth mentioning.
After I found out that my Serial COM ports don't work (via Portmon.exe), and figuring out that I may even don't have any (there is no COM port in Device Manager), I also tried to download a driver for COM port, but it has also failed.
Some say that it's because of my Acer Aspire 5742's motherboard. Some say that the reason is Windows 7.
Long story short, I'd really appreciate if someone can help me with my COM port problem and mend my broken dreams.

Installing Drivers for Arduino in Windows 8 / 7.
( I tried it for Uno r3, but i believe it will work for all Arduino Boards )
Plugin your Arduino Board
Go to Control Panel ---> System and Security ---> System ---> On the left pane Device Manger
Expand Other Devices.
Under Other Devices you will notice a icon with a small yellow error graphic. (Unplug all your other devices attached to any Serial Port)
Right Click on that device ---> Update Driver Software
Select Browse my computer for Driver Software
Click on Browse ---> Browse for the folder of Arduino Environment which you have downloaded from Arduino website. If not downloaded then http://arduino.cc/en/Main/Software
After Browsing mark include subfolder.
Click next ---> Your driver will be installed.
Collapse Other Devices ---> Expand Port ( its in device manager only under other devices )
You will see Arduino Written ---> Look for its COM PORT (close device manager)
Go to Arduino Environment ---> Tools ---> Serial Port ---> Select the COM PORT as mentioned in PORT in device manager. (If you are using any other Arduino Board instead of UNO then select the same in boards )
Upload your killer programmes and see them work . . .
I hope this helps. . .
Welcome

Did you install the drivers? See the Arduino installation instructions under #4. I don't know that machine but I doubt it doesn't have any COM ports.

I've had my drivers installed and the Arduino connected through an unpowered usb hub.
Moving it to an USB port of my computer made it work.

Abstract: Steps of How to resolve "Serial port 'COM1' not found" in fedora 17.
Today install the packages for Arduino in Fedora 17.
(yum install arduino) and I have the same problem: I decided to upload an example to the chip. and got the same error "Serial port 'COM1' not found".
In this case when I run Arduino program, some banner appears which warns me that my user is not in 'dialout' and 'lock' group. Do you want add your user in this groups? I click in add button, but for some reason the program fail and not say nothing.
Step1: recognize the Arduino device
unplug your Arduino and list /dev files:
#ls -l /dev
plug your Arduino and go and list /dev files
#ls -l /dev
Find the new file (device) that was not before plugging, for example:
ttyACM0 or ttyUSB1
Read this properties:
ls -l /dev/ttyACM0
crw-rw---- 1 root dialout 166, 0 Dec 24 19:25 /dev/ttyACM0
the first c mean that Arduino is a character device.
user owner: root
group owner: dialout
mayor number: 166
minor number: 0
Step2: set your user as group owner.
If you do:
groups <yourUser>
And you are not in 'dialout' and/or 'lock' group. Add yourself in this groups run as root:
usermod -aG lock <yourUser>
usermod -aG dialout <yourUser>
restart the pc, and set /dev/<yourDeviceFile> as your serial port before upload.

unplug not necessary,just uninstall your port,restart and install driver again.you will see arduino COM port under the LPT & PORT section.

This fix / solution worked for me:
Device Manager --> Ports --> right click on Arduino Uno --> Update Driver Software --> Search automatically for updated driver software

I restarted my computer and then opened the IDE again and it worked while none of the above did.
Maybe you have to do the things above as well, but make sure to restart the computer too.

Related

avrdude: ser_open(): can't open device "\\.\COM3": Access is denied

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
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!
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
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)
If your using the arduino IDE 2.0 you must close the serial monitor tab if it’s open to upload a sketch. Otherwise you will get this error.
USB may need CH340 driver.
Some Arduinos use the CH340 controller
Find and install the CH34X_Driver_V3.4_Windows.zip
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
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.
I had the same problem:
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.
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.
be sure you are not using 2 ides connected to arduino like ARDUINO IDE and VS Code
If you are using the USB-SERIAL CH340 driver: (on some cheaper ARDUINO clones)
Open Device Manager
Open Ports and click on the drop-down arrow to select your port.
Right-click and select "Properties"
Open the "Port Settings" tab.
Click on "advanced" to open a new window:
Un-tick "Use FIFO buffers (requires 16550 compatible UART)" and press "OK"
See image
Please let others know if this worked for you!

Arduino nano not responding

Few months ago, I bought cheap arduino nano from china. Instaled all the required drivers, and tried out my frirst program.
Now I tried to upload something new, and I get this error message:
avrdude: ser_open(): can't open device "\.\COM4": System can't find given file.
I also noticed, that Tools->Ports can not be clicked. The device does not even show up in device manager.
Any Ideas?
In my first program I did also set pin 0 and 1 (RX/TX) as outputs and used them to flash LEDs. I am aware, that this probably prevents new code from beeing uploded, but it should not prevent from the device from shoving up at all. The computer talking to the USB driver, not the microcontroller.
Go to Device Manager and find the Arduino COM Port
Go to the Advanced properties of the port
Set the port # to COM1
Then un-plug your USB and plug it back in.

COM port lockup with Mbed Virtual Serial Port

I am working with someone using Mbed and a LPCXpresso11U68 board.
I'm not intimately familiar with this particular board, but it has two USB connectors on it, one for the OpenSDA-ish debugger, and a second one is a direct connect to the CPU. I can connect both of these ports to my PC and attach a terminal emulator to each of them, and both ports show output (with a small installed program running on the board).
The device manager shows me that one port (COM51) is using "mbed Serial Port" driver and the other port (COM52) is using "Mbed Virtual Serial Port.
So far so good...
There is a reset button on the board. If I press that button, the port that is attached to the PC using the Mbed Virtual Serial Port driver (in my case COM52) stops operating. The other port (COM51) just restarts cleanly.
The problem I'm having is that after I exit the terminal program (note this happens with both TeraTerm and uCon), if I attempt to reconnect to that port, its not in the list of available comports. Strangely thought, it is still present in the Device Manager.
The only way I've found that I can clear this problem is to unplug/plug that usb cable (COM52) or issue a BREAK condition to COM51 (which AFAIK, resets the board).
I am the writer of uCon and I'd like to be able to detect this (which I can), and also be able to restart the comport connection without any other manual intervention.
One final note: apparently this is not specific to the LPCXpresso11U68 board; my guess it is some issue with the Mbed Virtual Serial Port driver.
Anyone have a clue what may be going on here?

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

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?
This is how I solved the problem. In Device Manager you will find the Arduino COM port.
Go to the Advanced properties of the port
Set the COM port number to COM1.
Then replug the USB.
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.
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.
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
I was having this same issue this morning. When I checked my Device Manager, it showed COM4 properly, and when I checked in the Arduino IDE COM4 just wasn't an option. Only COM1 was listed.
I tried unplugging and plugging my Arduino in and out a couple more times and eventually COM4 showed up again in the IDE. I didn't have to change any settings.
Hopefully that helps somebody.
Changing the port in Device Manager works for me. I was also able to fix it by finding the port that Arduino was using and then select it from the Adruion IDE from tools menu Tools>Port>Com Port
First, open Device Manager by searching for it in the Windows search bar.
Then, click ports and right click the port the Arduino is connected to. Then, go to Port settings → Advanced. Next, select any port that is not in use and is not the port the Arduino is currently connected to. Then click OK and unplug + replug your Arduino. This works most of the time with any Arduino board.
My solution: TOOLS > Processor > "old bootloader"

Arduino COM port not found

For the past week I have been programming an Arduino Uno with a computer running Windows 7. When I first started, I found the device on COM6 and was able to upload code no problem. Recently it suddenly stopped receiving code under the error:
Serial port 'COM6' not found. Did you select the right one from the
Tools > Serial Port menu?
The Serial port menu though is grayed out. Research has told me to open up Device Manager and update drivers but there is no other devices tab in my Device Manager. The Arduino is run off the power of the USB cable and runs the code I uploaded a few days ago just fine. What can I do to be able to upload code to the Arduino?
Update:
I installed the Arduino software on another computer and it does not recognize the Arduino either. One of the comments indicates that this could be a problem with the FTDI chip. How can I test if this is the case, and if it is, can I fix it?
There are two types of cable:
Charging Cable
Data Transfer Cable
So try changing the cable, if you have already tried every USB driver and port; or else
Install a new driver using this link, http://www.wch.cn/download/CH341SER_MAC_ZIP.html.
But after installing the driver, if it doesn't work, then change the cable.
For Linux:
To solve the problem, simply run the IDE as super user, so go to terminal and type 'sudo arduino'.
To solve this problem permanently:
In the terminal, run 'gksudo gedit'
In gedit, open the /usr/share/applications/arduino.desktop file.
Change the line Exec=arduino
to Exec=gksudo arduino. Save the file.
Similarly, do the same for Windows...
Also try to re-install Arduino driver.
The Arduino probably started using a different port. When you plug Arduinos into a different USB port it sometimes defaults to a new COM port. Check your device settings for which ports are being used and try each of those. Also try plugging it into a different USB port (if no ports are displayed) and it should register with a new COM. If that fails reboot your machine and repeat the above. If that fails reinstall the Arduino USB driver and repeat above. If that fails you might have fried your Arduino's USB chip (or some other hardware on the Arduino).
For Linux: Vinayk93 is completely right. Adjust the serial port's access rights like so:
$ cd /dev/ ; ls -l ttyA* -- find the right portname, then
$ sudo chmod 666 ttyACMx -- x is 0 or 1

Resources