I returned from a hiatus of using my Arduino Uno recently, and literally every single time I try to upload an example 01 Blink script to test, it keeps throwing this error:
Error: cannot set com-state for \\.\COM5
Error: unable to open port COM5 for programmer arduino
Failed uploading: uploading error: exit status 1
I've tried a lot to trouble shoot it, such as downloading that CH341SER file to tampering with the Windows Drivers, but literally nothing's working. I also believe this is a knock-off Arduino kit, though it was working perfectly fine a few years ago. I'd appreciate any help.
sorry I have not used an Arduino Uno in a very long time, so I am completely rusty and some of the questions/suggestions might not make sense.
As @b707 mentioned is the Serial Monitor open? Or any other window on COM5?
Do you have anything hooked up to the Serial pins (D0 and D1) on the board? They can
interfere with programming the board.
Does your board have a bootloader? Way back when, I would often used an AVR ISP (USB) to both debug stuff as well as program it, which may overwrite the bootloader.
Back then if I had used the AVR ISP, I might later have to burn the bootloader.
Alternatively you can use another UNO to burn the bootloader as well,
Sometimes I have issues with some COM ports not working properly, especially on earlier versions of windows. So sometimes I go through and delete all of the unused COM ports... Or some that I have problems with... Do a query on how to see all unused ports in device manager.
Sorry, just throwing out a few darts where hopefully one hits the target.
No, the Serial Monitor initially was not open, and this seems to be an issue with the USB itself probably (one time I used it a few years ago, it was also throwing errors, I just decided to use it today and magically hope the issue faded), it even fails for the simplest possible compilations
im happy that you resolved,but image represent a driver from 2024 and your probably is 2026 and in my case i use one more old tha 2024 and working,seem that new drivers have these problems