C version of esptool?

rezarethink
Posts: 20
Joined: Fri Mar 24, 2017 4:15 am

C version of esptool?

Postby rezarethink » Wed Sep 13, 2017 3:43 am

I will have an ESP32 and an STM32 on my PCB. I need to be able to perform OTA upgrades to both. Wondering if there is a C port of the esptool that will allow me to reflash the ESP32 from the STM32? The ESP32 that I'm using only has 16mbit of flash (internal) but the STM32 has 64mbit. Planning on having the firmware stores on the STM32 and pushing it out to the ESP32.

I would prefer to not port the esptool.py to C - is there any C code out there that I could use?

Thanks,
Reza

GreenGiant
Posts: 28
Joined: Tue Sep 10, 2019 7:22 am

Re: C version of esptool?

Postby GreenGiant » Wed Dec 18, 2019 8:27 am

Same here. I am going to be loading OTA updates to an esp32 over UART from an STM32 so need a c or c++ loader. Did you have any luck with this or is it a case of writing our own version of the python script in c?

vjacobs
Posts: 10
Joined: Mon May 20, 2019 8:34 am

Re: C version of esptool?

Postby vjacobs » Fri Dec 20, 2019 1:09 pm

Hello,

if your ESP32 is already running code (e.g. v1.0) which you then want to update (e.g. to v1.1), you can use the native OTA update functionality of the IDF to update your ESP and then send the actual binary through a link of your choice from the STM32 towards the ESP32. For example, you could devise some protocol over UART that sends the binary data from the STM32 to the ESP32. The receiving UART routine can then perform whatever check on the received binary data and use the OTA functions from the IDF to write to flash. This way, you can also use 2 partitions and dual boot.
This code then of course needs to be part of v1.0 already.

Andrzej
Posts: 7
Joined: Tue Mar 10, 2020 8:03 pm

Re: C version of esptool?

Postby Andrzej » Tue Mar 10, 2020 9:08 pm

Similar thread under a name 'IDF and ESPTOOL_PY Licence Clarification Request' is here: viewtopic.php?f=13&t=13805 .

Who is online

Users browsing this forum: No registered users and 73 guests