Hi everyone,
Can someone show me how to wirelessly upload my code to ESP32 which is present remotely far away but connected to internet. (Or atleast when connected to same router as my laptop.)
Wireless Code upload to ESP32
-
- Posts: 9759
- Joined: Thu Nov 26, 2015 4:08 am
Re: Wireless Code upload to ESP32
What you want is OTA (Over The Air) updates; esp-idf has an example for that.
Re: Wireless Code upload to ESP32
Can you please explain / suggest a reading material about how it works ?
-
- Posts: 9759
- Joined: Thu Nov 26, 2015 4:08 am
Re: Wireless Code upload to ESP32
Hey ,
Firstly thank you for the previous replies. I have gone through the links and were very useful. One thing that was not clear is about uploading code wirelessly more than once. Let me explain my problem in more detail - 1. Initially you uploaded the ota code into esp32 via usb.
2. Then it is connected to your wifi and then you uploaded another code (say blink) via wifi.
Now is it possible for me to upload another code(say hello_world) again wirelessly ?
(I got this doubt because the boot loader now automatically boots into ota_0 or ota_1 but not factory app where the actual ota code is present.)
Firstly thank you for the previous replies. I have gone through the links and were very useful. One thing that was not clear is about uploading code wirelessly more than once. Let me explain my problem in more detail - 1. Initially you uploaded the ota code into esp32 via usb.
2. Then it is connected to your wifi and then you uploaded another code (say blink) via wifi.
Now is it possible for me to upload another code(say hello_world) again wirelessly ?
(I got this doubt because the boot loader now automatically boots into ota_0 or ota_1 but not factory app where the actual ota code is present.)
-
- Posts: 9759
- Joined: Thu Nov 26, 2015 4:08 am
Re: Wireless Code upload to ESP32
The concept actually is that the factory app and ota1/ota2 app are incremental updates of eachother, all with the OTA functionality built-in. That way, you can always use the latest firmware in your ESP32 to OTA to a next version. The idea behind the factory app is that you could modify the bootloader to boot into it when e.g. the user presses a button; that way they have a way to do OTA even if OTA functionality in the later firmware is broken.
Re: Wireless Code upload to ESP32
Hi ESP_Sprite,
OTA is not working for me. This is what i have done:
1. Made (not flashed) the blink app and created python server.
2. Uploaded the OTA example code (changed the ip, port, app name etc. in menuconfig).
But the LED is not blinking i.e The code blink.bin is not uploaded into the partition(i guess).But it (esp32) has requested for the app as I can see the get request in the terminal. I have attached a screenshot of make monitor.
Thank you.
OTA is not working for me. This is what i have done:
1. Made (not flashed) the blink app and created python server.
2. Uploaded the OTA example code (changed the ip, port, app name etc. in menuconfig).
But the LED is not blinking i.e The code blink.bin is not uploaded into the partition(i guess).But it (esp32) has requested for the app as I can see the get request in the terminal. I have attached a screenshot of make monitor.
Thank you.
- Attachments
-
- Screen Shot 2017-07-03 at 5.39.49 PM.png (76.92 KiB) Viewed 11766 times
Re: Wireless Code upload to ESP32
Update :
The screen shot of python terminal is also attached. I think this could be due some problem in python server.
The screen shot of python terminal is also attached. I think this could be due some problem in python server.
- Attachments
-
- Screen Shot 2017-07-03 at 5.45.45 PM.png (101.4 KiB) Viewed 11766 times
Who is online
Users browsing this forum: No registered users and 86 guests