Problems uploading to ESP32 using arduino 2.3.6

I moved to windows 11 and to arduino 2.3.6 and not able to upload to the ESB32 developmend boards I used I get an esptool.util.UnsupportedCommandError: This command (0x14) is not supported in Secure Download Mode
[PYI-14924:ERROR] Failed to execute script 'esptool' due to unhandled exception!
Failed uploading: uploading error: exit status 1

I do not know this problem and how to solve it!

Sketch uses 274198 bytes (20%) of program storage space. Maximum is 1310720 bytes.
Global variables use 15676 bytes (4%) of dynamic memory, leaving 312004 bytes for local variables. Maximum is 327680 bytes.
"C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\tools\esptool_py\5.0.0/esptool.exe" --chip esp32s2 --port "COM8" --baud 115200 --before default-reset --after hard-reset write-flash -z --flash-mode keep --flash-freq keep --flash-size keep 0x1000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bootloader.bin" 0x8000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.partitions.bin" 0xe000 "C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.0/tools/partitions/boot_app0.bin" 0x10000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bin"
esptool v5.0.0
Serial port COM8:
Connecting....Traceback (most recent call last):
File "esptool.py", line 37, in

Connected to ESP32-S2 on COM8:
Chip type: ESP32-S2 in Secure Download Mode

Warning: Stub flasher is not supported in Secure Download Mode, it has been disabled. Set --no-stub to suppress this warning.

Enabling default SPI flash mode...

Hard resetting via RTS pin...
File "esptool_init_.py", line 1179, in main
File "esptool_init
.py", line 1036, in main
File "esptool\cli_util.py", line 227, in call
File "rich_click\rich_command.py", line 404, in call
File "click\core.py", line 1161, in call
File "rich_click\rich_command.py", line 187, in main
File "click\core.py", line 1697, in invoke
File "click\core.py", line 1443, in invoke
File "click\core.py", line 788, in invoke
File "click\decorators.py", line 33, in new_func
File "esptool_init_.py", line 689, in write_flash_cli
File "esptool\cmds.py", line 672, in write_flash
File "esptool\loader.py", line 1112, in get_security_info
File "esptool\loader.py", line 539, in check_command
File "esptool\loader.py", line 509, in command
esptool.util.UnsupportedCommandError: This command (0x14) is not supported in Secure Download Mode
[PYI-14924:ERROR] Failed to execute script 'esptool' due to unhandled exception!
Failed uploading: uploading error: exit status 1

So what exact Esp32-board you have and do you have something connected to gpio pins?

I have several boards in use. Only one I can uploads code from the arduino IDE:

working : esp-wroom-32 on the back site of this developmend board esp32s whith backside

pins not connected

notworking: My own developed board esp32wroom32e not working any more

pins connected

not working: esp- wroom-32 backside esp32 devkit v1 not working all 3 boards

pins not connected

It is working in my windows 10 PC but after switching to an other computer using windows 11 it is not working any more

So I wonder from where this comes from:

Hai In the end I have tryed several boards using the board manager but that is not helping. What you see is the last tryout

Only one board is working

This is the working developmend board V1

ketch uses 298199 bytes (22%) of program storage space. Maximum is 1310720 bytes.
Global variables use 20772 bytes (6%) of dynamic memory, leaving 306908 bytes for local variables. Maximum is 327680 bytes.
"C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\tools\esptool_py\5.0.0/esptool.exe" --chip esp32 --port "COM8" --baud 115200 --before default-reset --after hard-reset write-flash -z --flash-mode keep --flash-freq keep --flash-size keep 0x1000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bootloader.bin" 0x8000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.partitions.bin" 0xe000 "C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.0/tools/partitions/boot_app0.bin" 0x10000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bin"
esptool v5.0.0
Serial port COM8:
Connecting.....
Connected to ESP32 on COM8:
Chip type: ESP32-D0WD-V3 (revision v3.1)
Features: Wi-Fi, BT, Dual Core + LP Core, 240MHz, Vref calibration in eFuse, Coding Scheme None
Crystal frequency: 40MHz
MAC: e4:65:b8:10:0b:b4

Uploading stub flasher...
Running stub flasher...
Stub flasher running.

Configuring flash size...
Flash will be erased from 0x00001000 to 0x00007fff...
Flash will be erased from 0x00008000 to 0x00008fff...
Flash will be erased from 0x0000e000 to 0x0000ffff...
Flash will be erased from 0x00010000 to 0x00058fff...
Compressed 25168 bytes to 16063...

Writing at 0x00001000 [ ] 0.0% 0/16063 bytes...

Writing at 0x00007250 [==============================] 100.0% 16063/16063 bytes...
Wrote 25168 bytes (16063 compressed) at 0x00001000 in 1.6 seconds (127.9 kbit/s).
Hash of data verified.
Compressed 3072 bytes to 146...

Writing at 0x00008000 [ ] 0.0% 0/146 bytes...

Writing at 0x00008c00 [==============================] 100.0% 146/146 bytes...
Wrote 3072 bytes (146 compressed) at 0x00008000 in 0.0 seconds (730.6 kbit/s).
Hash of data verified.
Compressed 8192 bytes to 47...

Writing at 0x0000e000 [ ] 0.0% 0/47 bytes...

Writing at 0x00010000 [==============================] 100.0% 47/47 bytes...
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.0 seconds (1560.1 kbit/s).
Hash of data verified.
Compressed 298352 bytes to 157846...

Writing at 0x00010000 [ ] 0.0% 0/157846 bytes...

Writing at 0x0001c9b1 [==> ] 10.4% 16384/157846 bytes...

Writing at 0x00029954 [=====> ] 20.8% 32768/157846 bytes...

Writing at 0x0002f133 [========> ] 31.1% 49152/157846 bytes...

Writing at 0x00034c4b [===========> ] 41.5% 65536/157846 bytes...

Writing at 0x00039e4d [==============> ] 51.9% 81920/157846 bytes...

Writing at 0x0003f488 [=================> ] 62.3% 98304/157846 bytes...

Writing at 0x00044cef [====================> ] 72.7% 114688/157846 bytes...

Writing at 0x0004f5ea [=======================> ] 83.0% 131072/157846 bytes...

Writing at 0x00055371 [===========================> ] 93.4% 147456/157846 bytes...

Writing at 0x00058d70 [==============================] 100.0% 157846/157846 bytes...
Wrote 298352 bytes (157846 compressed) at 0x00010000 in 14.2 seconds (168.2 kbit/s).
Hash of data verified.

Hard resetting via RTS pin...

And this is the not working developmend board:

Sketch uses 298199 bytes (22%) of program storage space. Maximum is 1310720 bytes.
Global variables use 20772 bytes (6%) of dynamic memory, leaving 306908 bytes for local variables. Maximum is 327680 bytes.
"C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\tools\esptool_py\5.0.0/esptool.exe" --chip esp32 --port "COM8" --baud 115200 --before default-reset --after hard-reset write-flash -z --flash-mode keep --flash-freq keep --flash-size keep 0x1000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bootloader.bin" 0x8000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.partitions.bin" 0xe000 "C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.0/tools/partitions/boot_app0.bin" 0x10000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bin"
Sketch uses 298199 bytes (22%) of program storage space. Maximum is 1310720 bytes.
Global variables use 20772 bytes (6%) of dynamic memory, leaving 306908 bytes for local variables. Maximum is 327680 bytes.
"C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\tools\esptool_py\5.0.0/esptool.exe" --chip esp32 --port "COM8" --baud 115200 --before default-reset --after hard-reset write-flash -z --flash-mode keep --flash-freq keep --flash-size keep 0x1000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bootloader.bin" 0x8000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.partitions.bin" 0xe000 "C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.0/tools/partitions/boot_app0.bin" 0x10000

This is the notworking developmend board esp32 devkit v1

Sketch uses 285227 bytes (21%) of program storage space. Maximum is 1310720 bytes.
Global variables use 20680 bytes (6%) of dynamic memory, leaving 307000 bytes for local variables. Maximum is 327680 bytes.
"C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\tools\esptool_py\5.0.0/esptool.exe" --chip esp32 --port "COM8" --baud 115200 --before default-reset --after hard-reset write-flash -z --flash-mode keep --flash-freq keep --flash-size keep 0x1000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bootloader.bin" 0x8000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.partitions.bin" 0xe000 "C:\Users\Jniva\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.3.0/tools/partitions/boot_app0.bin" 0x10000 "C:\Users\Jniva\AppData\Local\arduino\sketches\054A7F3539BA6D5AE36FA0F1D75D85DD/Blinkled2.ino.bin"
esptool v5.0.0
Serial port COM8:
Connecting.....
A fatal error occurred: Invalid head of packet (0x55): Possible serial noise or corruption.

Failed uploading: uploading error: exit status 2

Hi @jnivard.

It is possible for a short or external circuitry connected to the Arduino board to interfere with the upload process, causing this type of upload error.

Make sure the board is not sitting on anything conductive that could short the contacts on the bottom of the board. Make sure there isn't any conductive debris (e.g., loose beads of solder, strands of wire, or component leads) on the board or on the surface the board is sitting on.

If you have a shield or any external circuitry or components connected to your Arduino board, try this experiment:

  1. Disconnect the USB cable of the Arduino board from your computer.
  2. Disconnect any shields, modules, external circuitry, etc. from your board.
  3. Connect the Arduino board to your computer with a USB cable.

Now try uploading a sketch to the board again. Does the upload succeed?

This experiment will determine whether the upload error was caused by interference from your external circuitry. If so, you can then focus your attention on identifying the specific problem with the circuit and resolving it.

Maybe the old working Win10 laptop had plastic chassis... :wink:

I have instaled the arduino version 1.8.19 on this windows 11 PC.

In windows I can see when I plug in the USB connector in the developmend board I see the CP210x USB comming up on com8. when I connect a next devboard it is comming up as com9. So the usb ports are recognisched by windows.

When I start the IDE I can see that the com port 8 is disabled. also com port 9 The speed is correctly set 115200

According the IDE the ports are 8 and 9 disabled but in windows all looks ok

I'm not sure I understood correctly what you mean by "is disabled". Please provide a more detailed description of what you mean in a reply on this forum topic to help us to understand it.

Ok when I start the IDE and open the blink schetch on the bottum line of the serial monitor you see the status one of this status remark is Disabled on com9 or 8 when connected to com8

Please make a stronger effort to communicate clearly. Your post is very disorganized and impossible to understand. You might think you are saving time by quickly writing a sloppy reply, but I assure you that it is just the opposite. The forum helpers are often able to provide a solution within a matter of minutes when provided with sufficient information, but we also often see support requests drag out for days or weeks due to ambiguity and confusion caused by ineffective communication.

Are you referring to a "[not connected]" text on the Arduino IDE status bar?:

Yes, in my dutch version it is called disabled.

removing the USB connector in windows I can see the silicon Labs CP210x disapiering. That means Windows is seeing the USB port as active

So if you connect the "working board" to usb, windows detects it as CP210x and on IDE you have com port available for it. Selecting Esp32 Dev Module you can upload the sketch.

And if you now disconnect that board and replace it with "non working board", windows detects it as CP210x, but IDE doesn't give any com port available for it?

Yes that is the case. two screenshot both icluding the windows CP210 status of com8

case

This is both arduino 2.3.6 windows 11

I wil repeat it for 1.8.19 windows 11

Arduino 1.8.19

The working chip is compiling. The port is in the IDE market as Disabled op com8, but available in windows.

The not working board is compiling but not uploaded. The error message is “board not connected”. The port is in the IDE market as disabled, but you can see it in windows

I see now that you were referring to the Arduino IDE 1.x interface when you wrote this:

You misinterpreted what you saw. Unlike 2.3.6, Arduino IDE 1.8.19 doesn't give any indication of the state of the serial port.

The "disabled" you saw on the Arduino IDE 1.8.19 status bar is the option you have selected from Arduino IDE's Tools > Erase All Flash Before Sketch Upload menu. So it is only telling you about the configuration of the board in Arduino IDE. It is not in any way related to the serial port of the board.

Ok thank you for that remark

But the problem I have under windows 11 persist. Only 1 board is working. I will recover my old PC windows 10 and will check ow it is going on that configuration using the existing software and new software

I think now it has to do with the board manger selected configuration and perhaps it need upgrades for windows 11

Thanks for helping

Hai

I configured my old PC using windows 10:

1 Arduino EDI version 1.8.13 all my 6 boards are working ok

2-Arduino EDI version 2.3.4 allo my 6 boards are working ok

Moving to Windows 11

1-Arduino EDI version 1.8.19 only 1 developmend board ESPO32S ID:AC7Z-ESP-WROOM32 is working

2Arduino EDI version 2.3.6 only 1 developmend board ESPO32S ID:AC7Z-ESP-WROOM32 is working

3Arduino EDI version 2.3.6 developmend board ID: 2BCLP esp32S is not working

4Arduino EDI version 2.3.6 developmend board ID: 2AC7Z ESPWROOM is not working

5 Arduino EDI version 2.3.6 developmend board ID: 2AC7Z ESP-WROOM-32E is not working id 2AC7Z ESP-WROOM-32E

I have tryed several boards using the board manager but that is not helping