Sanity Check for Uploading Code to DevKitC-1 Using Arduino IDE (Solved)

carboy66
Posts: 2
Joined: Sat Nov 04, 2023 11:40 pm

Sanity Check for Uploading Code to DevKitC-1 Using Arduino IDE (Solved)

Postby carboy66 » Sun Nov 05, 2023 12:07 am

(I've searched for this in other posts but have not found much to help)

I apologize in advance, this is not going to be an exciting post, (you might even roll your eyes), but it would be much appreciated if you helped. Because I get no error messages I have no idea how to progress

I am trying to upload code to a ESP32-S3 DevKitC with Arduino IDE.
This is the example I am following: https://hutscape.com/tutorials/hello-arduino-esp32s3

I've added additional boards manager URLs:
https://dl.espressif.com/dl/package_esp32_index.json
https://espressif.github.io/arduino-esp ... index.json
https://raw.githubusercontent.com/espre ... index.json

I've downloaded both ESP32 and Arduino ESP32 Boards packages from the boards managers

I've selected ESP32S3 Dev Module as my board and made sure it has the right port, (happens to be COM14)

I've set the board preferences as shown in "Screenshot (470)" but I have no idea if that is correct.

The hello world code pulled from the example compiles fine

If I do not press any buttons I receive the messages shown in the picture "error messages"

If I press the boot button, then the reset button I get the message shown in the picture "waiting download"

If I do not press any more buttons and I upload the code I get the message:
Changed.
Configuring flash size...
Flash will be erased from 0x00000000 to 0x00003fff...
Flash will be erased from 0x00008000 to 0x00008fff...
Flash will be erased from 0x0000e000 to 0x0000ffff...
Flash will be erased from 0x00010000 to 0x0004bfff...
Compressed 15088 bytes to 10374...
Writing at 0x00000000... (100 %)
Wrote 15088 bytes (10374 compressed) at 0x00000000 in 0.2 seconds (effective 515.1 kbit/s)...
Hash of data verified.
Compressed 3072 bytes to 146...
Writing at 0x00008000... (100 %)
Wrote 3072 bytes (146 compressed) at 0x00008000 in 0.0 seconds (effective 517.7 kbit/s)...
Hash of data verified.
Compressed 8192 bytes to 47...
Writing at 0x0000e000... (100 %)
Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.1 seconds (effective 707.8 kbit/s)...
Hash of data verified.
Compressed 244752 bytes to 135004...
Writing at 0x00010000... (11 %)
Writing at 0x0001daa3... (22 %)
Writing at 0x0002429d... (33 %)
Writing at 0x000295a3... (44 %)
Writing at 0x0002eaf8... (55 %)
Writing at 0x0003718c... (66 %)
Writing at 0x0003f442... (77 %)
Writing at 0x00044908... (88 %)
Writing at 0x0004a39b... (100 %)
Wrote 244752 bytes (135004 compressed) at 0x00010000 in 2.7 seconds (effective 730.0 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting via RTS pin...


None of the programs I have tried to flash have worked. I've made sure the baud rate is the same between the code and the serial monitor.
I've read that in order to get the board into flash mode, I need to:
Not hit any buttons
Hold the boot button until Arduino IDE puts out "Connecting..."
Hold the boot button until the process is over
Hold the boot button first then the reset button
Not do any of these but press the reset button after the code uploads
The technical manual, (on page 520), says that I need to ground GPIO 0 and GPIO46.
Some websites claim to ground GPIO0 and GPIO6
Some websites claim that I need to put a 10uF electrolytic capacitor between EN and GND, (I assume EN and RESET are the same? Since my board does not have a EN pin)
Some claim to not need any of that
WHAT IS HAPPENING?

When I hold boot than reset that seems to put the board into a flashing mode but then the code doesn't run.
Attachments
Screenshot (470).png
Screenshot (470):
Board preferences
Screenshot (470).png (131.14 KiB) Viewed 6575 times
error messages.PNG
error message:
Monitor error messages when pressing no buttons
error messages.PNG (65.06 KiB) Viewed 6575 times
Last edited by carboy66 on Thu Jan 11, 2024 12:42 am, edited 1 time in total.

lbernstone
Posts: 829
Joined: Mon Jul 22, 2019 3:20 pm

Re: Sanity Check for Uploading Code to DevKitC-1

Postby lbernstone » Sun Nov 05, 2023 5:10 am

On ESP32-S3 devkitc, there are two usb connectors. One is labelled USB, and the other UART. If you use the UART connector, you should disable USB-CDC on boot. If you use the USB connector, you should have that enabled. I would recommend that you use the UART until you get your bearings. It will show you all the output, even in a reboot loop.
There are two models of ESP32-S3 modules. They are marked on the module. The WROOM-2 should use OPI flash (and OPI psram). The WROOM-1 should use QIO flash (and psram, if present).
You are uploading firmware to the device properly, so there is no need to add any capacitors or strapping pins.

carboy66
Posts: 2
Joined: Sat Nov 04, 2023 11:40 pm

Re: Sanity Check for Uploading Code to DevKitC-1

Postby carboy66 » Thu Jan 11, 2024 12:40 am

SOLUTION:

1 Go to https://www.silabs.com/developers/usb-t ... umentation and download the CP210x Driver, (I have Windows 10 and used the universal Windows driver). Unzip the folder and right click on silabser.inf and select install. Proceed until download is successful. (What is this doing? This downloads firmware that allows the ESP32 to communicate with your PC via UART).
2 On the board connect to UART port, not USB port.
3 Match the settings in the picture. Choose the COM port that automatically appears. (If it doesn't appear, there may be two issues: 1. The wrong driver was downloaded, do some research to find what driver Espressif requires 2. Sometimes Arduino IDE does not automatically detect devices so try each COM port manually.)
Screenshot (520).png
The correct settings
Screenshot (520).png (121.15 KiB) Viewed 6688 times
4 Now you must prep it for programming. Open serial monitor, (double check your baud rate matches). Hold the BOOT button, press and release RESET button, then release the BOOT button. The serial monitor should say "waiting for download" or something of the sort.
5 Upload the code and it should work



You can use this code to double check it uploaded successfully:
https://hutscape.com/tutorials/hello-arduino-esp32s3

Who is online

Users browsing this forum: No registered users and 152 guests