DIYOSEPP / EspUnoWiFi

WiFi Serial and OTA bridge for UNO
23 stars 10 forks source link

Osepp UnoR3 Plus ATmega328p + ESP-01 (ESP8266) cannot update ATmega328p sketch thru wifi #11

Open brunoaduarte opened 1 year ago

brunoaduarte commented 1 year ago

Hi @DIYOSEPP I'm trying to use the EspUnoWiFi with my Osepp Uno R3 Plus (ATmega328P) + ESP01 (ESP8266) shield. https://osepp.com/electronic-modules/microcontroller-boards/105-osepp-uno-r3-plus

I can successfully upload the sketch to the ESP-01 (ESP8266) via USB, connect to my Wifi router and update ESP8266 sketches thru wifi.

Local IP    192.168.1.179
subnetMask  255.255.255.0
gateway         192.168.1.254
dns         192.168.1.254
"C:\Users\Myself\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1/python3" -I "C:\Users\Myself\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\3.1.2/tools/espota.py" -i "192.168.1.179" -p "8266" "--auth= " -f "C:\Users\Myself\AppData\Local\Temp\arduino\sketches\8FE687328083CBB82362CEEDFC8E6D8D/EspUnoWifi.ino.bin"
Uploading..................................................................................................................................................................................................................................................................

But when I try to update the ATmega328p thru wifi (OTA) I get an error

Sketch uses 922 bytes (2%) of program storage space. Maximum is 32256 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2039 bytes for local variables. Maximum is 2048 bytes.
"C:\Users\Myself\AppData\Local\Arduino15\packages\arduino\tools\arduinoOTA\1.3.0/bin/arduinoOTA" -address 192.168.1.179 -port 8266 -sketch "C:\Users\Myself\AppData\Local\Temp\arduino\sketches\959FEC3A08A3218CFA0F1A4E0C565DCD/Blink.ino.hex" -upload {upload.port.properties.endpoint_upload} -sync {upload.port.properties.endpoint_sync} -reset {upload.port.properties.endpoint_reset} -sync_exp {upload.port.properties.sync_return}
Resetting the board
Failed to reset the board, upload failed
Failed uploading: uploading error: exit status 1

Arduino IDE version image

Seems it's generating the upload line incorrectly with the latest IDE

-upload {upload.port.properties.endpoint_upload} -sync {upload.port.properties.endpoint_sync} -reset {upload.port.properties.endpoint_reset} -sync_exp {upload.port.properties.sync_return}

fsinnes commented 1 year ago

Did you figure this out? I am also getting an incorrect upload line

brunoaduarte commented 1 year ago

Did you figure this out? I am also getting an incorrect upload line

Just use an older IDE of Arduino, like 1.8.X. Seems there's a bug with the parameters parsing on the newer versions.