CH340 driver rollback workaround works on Windows 10 but not 11

Continuing the discussion from Windows 11 Arduino IDE version 2.1.1 COM Port Problem:

Hi, this is excattly what I've done and it does not work on Windows 11 (But it works on Windows 10)
Think that these driver's lastest update is 26 jan 2015
And Windows 11 is borned on 5 Oct 2021 !
So when can we get a driver really tested on windows 11 ?

Please create a new thread, it's good practice for several reasons. Thank you.

Please provide a detailed explanation of what you mean by this, including:

  • What did you do?
  • What were the results you expected from doing that thing?
  • What were the results you observed that did not match your expectations?

Make sure to include the full and exact text of any error or warning messages you might have encountered.

Posts split to dedicated topic as suggested.

Carry on.

Which devices have the CH340 chip, any Arduinos?

And the driver in question that isn't working, is this the one (topmost):

https://www.catalog.update.microsoft.com/Search.aspx?q=CH340%20drivers

Hi, undertood that I had to create a new thread but do not know how to
So : As I say , I'm using Arduino software on Linux Fedora without any trouble, on Windows 10 without any trouble but it's impossible to deal with on Windows 11.
I've tried with same Arduino nano card and same cable (as it works on other OS... other OS = other computer : there are NO virtual OS)
I've done exactelly the same things:
1st download lastest Arduino software (mine is X64 exe for windows)
2nd : software installation
3rd : downaload ch341.exe and installation
4th : connecting Arduino card : new hardware is detected as USB-CH340 (COM3)
5th Launching Arduino software
6th accept updating card list
7th Select my Card (Arduino Nano)
8th Select my processor (Old bootloader : I know it is : because it works with Win 10 and Fedora)
9th Select port com (COM3 as Windows tell me that CH340 gives me port COM3)
10th Loading a very simple sketch
11th Compiling sketch (It does not provide any errors)
12th Trying to Upload and then .............. avrdude: ser_open(): can't set com-state for "\.\COM3"
Failed uploading: uploading error: exit status 1
There is no documentation about this error

I've tried with Lastest Arduino software (by website), Arduino 2.1, Arduino 1.8 and Arduino by Windows store : It gives always the same error.

I've found (google) other people having the same trouble with same error with Arduino on windows 11. Nobody had never find how to fix it.

Just found something strange : If I enable serial enumerator (advanced settings on windows devices serial port window) I can do one and only one upload successfully.
Then, to make another successful serial communication with the Arduino board, I have to disable serial enumerator and then renable serial enumerator etc...

Yeap Arduino nano has
Thanks for your suggestion, just retry (because i've already try).
Of course I've begun by deleting my driver ...
But it's the same results
avrdude: ser_open(): can't set com-state for "\.\COM3"
Failed uploading: uploading error: exit status 1

I know what is opening or closing a serial port what is reading an writing dealing with a serial port but what is "setting com state" ?

Speed, parity, stop bits, handshake, etc

Ok, I was going to say that it's up to the chip manufacturer to produce a driver that works, but if there's an official Arduino board maybe you can bug them about it too :cowboy_hat_face:

I did it for you already. Please don't create a new thread.

@ledsyn this would be good advice if it could be made in advance (which is sometimes possible), but telling people to create a new thread after they already posted is problematic because you are encouraging them to cross-post, which is against the forum rules.

In this case it is better to flag the existing post and let the moderators take care of it:

Got it. :ok_hand:

1 Like

This is incorrect. The Arduino Nano uses the FTDI FT232R USB chip, not CH340. The board you are referring to as "Arduino nano" is not an Arduino Nano but instead a cheap Chinese derivative of the Arduino Nano.

The CH340 is not used on any official Arduino board.

Thanks, very interresting.
I've taken a look at your link, and you're right
There are some things strange : When I plug my arduino borad on Fedora Linux (wich Arduino software work), dmesg says : "ch341 1-1:1.0: ch341-uart converter detected"
So , linux kernel find a ch341 and everything works fine
On windows 10, my driver is CH340 and every thing works fine
On windows 11 , using CH341 driver makes uploading fail ????
So I've searched an FTDI driver. I only found a VPC driver (does not make sens ... don't want a virtual serial port) at VCP Drivers - FTDI
And windows tels me that this driver is not compatible with my device
Last information : searching in windows devices options, I've found 2 Arduino manufacturer with a lot of arduino devices but no Arduino nano.
Is there a specific driver for my Arduino nano and where can I find it ?

For information : Windows 11 OS says that My device is USB\VID_1A86&PID_7523\5&2DC4D53B&0&2
And VendorID 1A86 / Product ID 7523 is for Nanjing Qinheng Electronics CH340

So, My Ardnuino nano board would not be an Adruino nano board ?
If true then CH340 driver is the good driver and ch340 driver DO NOT WORK on Windows 11
If not true, then CH340 driver works on all OS (Linux too) EXCEPT Windows 11

It's not an official board no but a clone. Even you can build a Nano clone yourself, the schematics is available publicly!

I wouldn't go to that extent that it's the same driver for both Linux and Windows. The drivers for the Linux kernels are maintained by the kernel team.

I've never said that Linux and windows has to have the same driver !
I've said that it works on Windows 10 with CH340 driver, it works on Linux with CH340 driver and it do not work with Windows 11 with CH340 driver

For information none of my boards are uploadable on Windows 11 but they are all uploadable with Windows 10 and Linux
I've tried
my Arduino Uno board
And all of my ESP32 boards

So the trouble is not about my boards , it is not about my wiring, it's about the driver (or perhaps the software)

You got an official Uno? Then as @ptillisch said, it's another chipset.

Edit:

Sorry, I didn't see your distinction.

Did you perform the driver rollback procedure I described in the other thread?:

Even if you install the working older version of the driver, Windows will automatically update the driver to the newer version that is incompatible with the bad CH340 chips. This is why you must perform the "roll back driver" procedure to force Windows to persistently use the old version of the driver.

It is difficult to survey because most of the affected users didn't report which version of Windows they are using, but there are definitely some Windows 11 users who have been able to solve the problem by using the older driver version. I found these reports after a quick search:

And another even in the forum topic you originally posted in!:

https://forum.arduino.cc/t/windows-11-arduino-ide-version-2-1-1-com-port-problem/1148176

It is true that the symptom reported there is different (opening Serial Monitor fails with a "Port monitor error command ‘open’ failed: Invalid serial port." error instead of upload failing with a "can't set com-state" error), but both symptoms have the same cause and the same workaround.

There is another report of a Windows 11 user solving that symptom with the "roll back" technique here:

https://forum.arduino.cc/t/weird-issues-with-ide-2-2-1/1179568/6

Since you have verified that your board has a CH340 chip, it is a waste of time to try to install the FTDI drivers.

Do all of those boards have CH340 chips?

Does the upload to all of the boards fail with the "can't set com-state" error, or do you get a different error message?

Someone understood me !!!!!
Yeap, It seems that Windows 11 had always installed the newest driver ! (But not on Windows 10 ... strange)
First the first time since one year (since I've bought a new computer under windows 11) I can upload a sketch to my arduino board with success !
Hoping after a reboot I can always do that
Thank's a lot !
For information , if it can help someone else : this driver installation program tells me that there was an error during installation. I have first to plug my board to see the serial port device , uninstall the hardware in the device manager , clicking in the box to try to delete the driver first. Then unplug my myboard, and install this old driver. Then it works.

You are welcome. I'm glad it is working now. Thanks for taking the time to post an update with your findings.

Regards,
Per

Hello, I have also several (chinees) nano's with problems.
But they are al working well at Win10.
Only the types with NO CH340 number pressed on the chip are giving problems.
The REAL CH340 chips are werking well.
I believe that there is a CH340 clone, the wire connections are also not the same who are giving the problems. This chip has NO CH340 on the chip, it is blanco.
At the uppersite of the NANO you can see the diffence.
The good ones has 6 rounds at the ISCP connection.
The bad ones has 5 rounds and ONE (for pin1) And NO type number on the chip.
But i have NO solution found for this problem. I also don't know what the REAL typenumber of this chip.