can't upload using Arduino 2.1.1
-
I have a couple ESP32 T-Display S3 boards that I can't seem to upload any code to either of them using Arduino 2.1.1; although this has worked fine for me in the past.
I'm not sure if its the version of Arduino that is behind the problem, or something else.
Currently, I'm just trying to get the ota example to upload.
It compiles, and the upload starts, but ends like this ...
Writing at 0x00075246... (58 %)
Writing at 0x0007a0c6... (62 %)
Writing at 0x0007f13c... (65 %)
Writing at 0x00084279... (68 %)
Writing at 0x000894f1... (72 %)
Writing at 0x0008eaa2... (75 %)
Writing at 0x0009489f... (79 %)
Writing at 0x00099ee2... (82 %)
Writing at 0x000a26fa... (86 %)
Traceback (most recent call last):
File "esptool\loader.py", line 375, in command
File "esptool\loader.py", line 307, in read
File "esptool\loader.py", line 1415, in slip_reader
esptool.util.FatalError: Serial data stream stopped: Possible serial noise or corruption.During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "esptool.py", line 34, in <module>
File "esptool_init_.py", line 1004, in main
File "esptool_init.py", line 806, in main
File "esptool\cmds.py", line 502, in write_flash
File "esptool\loader.py", line 108, in innerI have tried other projects, but they fail to upload too (often earlier when they are larger in size).
I've tried lowering the upload speed, but that didn't help.
Anyone else having issues with Arduino 2.2.1 ?
-
@roblatour Hey Rob, Terry here!
Send me the simplest sketch that does not compile and I will try and upload it here on my M1 iMac with v2.1.1 Arduino IDE.P.S. I have to ask(!) if the HotHead.ino will still compile?
This is what I get:
Sketch uses 356833 bytes (11%) of program storage space. Maximum is 3145728 bytes. Global variables use 21196 bytes (6%) of dynamic memory, leaving 306484 bytes for local variables. Maximum is 327680 bytes. esptool.py v4.5.1 Serial port /dev/cu.usbmodem101 Connecting... Chip is ESP32-S3 (revision v0.1) Features: WiFi, BLE Crystal is 40MHz MAC: 68:b6:b3:22:4c:6c Uploading stub... Running stub... Stub running... Changing baud rate to 921600 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 0x00067fff... Compressed 15040 bytes to 10333... Writing at 0x00000000... (100 %) Wrote 15040 bytes (10333 compressed) at 0x00000000 in 0.4 seconds (effective 280.5 kbit/s)... Hash of data verified. Compressed 3072 bytes to 137... Writing at 0x00008000... (100 %) Wrote 3072 bytes (137 compressed) at 0x00008000 in 0.1 seconds (effective 253.4 kbit/s)... Hash of data verified. Compressed 8192 bytes to 47... Writing at 0x0000e000... (100 %) Wrote 8192 bytes (47 compressed) at 0x0000e000 in 0.2 seconds (effective 381.0 kbit/s)... Hash of data verified. Compressed 357200 bytes to 195969... Writing at 0x00010000... (8 %) Writing at 0x0001832d... (16 %) Writing at 0x00020996... (25 %) Writing at 0x0002d475... (33 %) Writing at 0x00034e10... (41 %) Writing at 0x0003a93d... (50 %) Writing at 0x0003ffa0... (58 %) Writing at 0x0004533c... (66 %) Writing at 0x0004b741... (75 %) Writing at 0x00055ca0... (83 %) Writing at 0x0005c10b... (91 %) Writing at 0x0006189e... (100 %) Wrote 357200 bytes (195969 compressed) at 0x00010000 in 4.5 seconds (effective 640.3 kbit/s)... Hash of data verified. Leaving... Hard resetting via RTS pin...
-
@teastain2 said in can't upload using Arduino 2.1.1:
Hi @teastain2,
Thanks for your help.
I have just sent you the file at the email you have noted above.
Basically, its the OTA example for the LilyGo T-Display S3.
It needs LilyGo's TFT Libaray.
Of note, it compiles just fine, however it will not fully upload.
Thinking if I could get the OTA example to upload on another computer, then I could just use my normal computer to make changes to the code and upload it via OTA (rather then via the usb) moving forward.
Sadly, I am having the same problem on the other computer too.
I have also tried updating the esp32 board definitions; the CH341SER driver on both machines, and various USB cables - just no love.
-
Thanks again for your help, and for confirming Arduino 2.1.1 was working fine with the LilyGo T-Display S3 on your system.
After spending virtually the whole day on this, I was able to pin-point the problem and work out a solution.
First, let me say I have also been using the ESP-IDF for some projects.
With that in mind, somewhere along the line I updated the CH430/431 driver to its most current version (3.8).
This turned out to have been at the root of the problem. Finding this post: https://github.com/espressif/esptool/issues/879 I tried reverting the driver to version 3.5, but that alone did not resolve the problem - although it was indeed the key part of the solution.
After downgrading the driver, the sketch would still not upload on either of the two LilyGo T-Display S3 boards which I was working with via the Arduino IDE 2.1.1.
However, I found that I could upload a very basic "hello world" like sketch to the LilyGo T-Display S3 using the ESP-IDF. Also, once I did this, I could then upload the sketch that I needed to the same board using the Arduino IDE.
In other words, it appears not only did the use of the current CH430/431 driver (3.8) prevent uploads to the LilyGo T-Display S3, it also somehow appears to have corrupted the flash in the board such that even with the right driver the Arduino IDE could not upload to it.
Using the ESP-IDF to upload to the board, seems to have reset things such that the Arduino IDE would again work fine with the 3.5 version of the CH430/431 driver.
I repeated the process with my second LilyGo T-Display S3 and got the exact same positive results.
Just posting this here in case it will be of use to others.
Thanks again to @teastain2 on this forum, and xamfa, radimkarnis. and mentesix on the Espressif forum for there help and posting toward this resolution.