Hello guys, how are u? I hope that you're all good
I was wondering about producing devices using ESP32 in a large scale. Is it possible to flash multiples ESP32 at the same time? Like, connect a bunch of ESP32 on a unique line of communication with PC and flash the same firmware for all the microcontrollers all at once.
I tought about it because the company that i work for has plans to produce 3000 devices next semester, and i mean, flash 3000 esp32 it will require sometime of my team , so i'm trying to figure out a better way to do this task
Regards,
Matheus
Flash multiples ESP32 at the same time
-
- Posts: 9757
- Joined: Thu Nov 26, 2015 4:08 am
Re: Flash multiples ESP32 at the same time
There isn't really an error-proof way to hook up multiple ESP32s to one serial line and flash them all, as you can't reliably see if one ESP32 fails to flash. The closest you could get would be to connect a lot of USB-serial converters to a PC and then spin up a bunch of esptool.py instances in parallel, one for each port. You may want to add some scripting around it that e.g. indicates the status of each ESP32 and asks the operator to replace them with a new one as soon as they're done programming.
I know it's possible to order modules/chips pre-flashed with your firmware as well, although I'm not sure what the MOQ for that is... you may want to send off a mail to sales@espressif.com if you're interested in that.
I know it's possible to order modules/chips pre-flashed with your firmware as well, although I'm not sure what the MOQ for that is... you may want to send off a mail to sales@espressif.com if you're interested in that.
Re: Flash multiples ESP32 at the same time
I am making all of my devices being able to do OTA from the web server.
And then, I compile all files, put them on server, and then, send 1 command over MQTT to all devices.
When they wake up (most of them sleep and only wake up to perform measurements and send to home assistant, then they go to sleep again), MQTT command is waiting for them, once message is received each of them, one by one starts upgrade.
The devices that don't sleep, perform upgrade the moment the command is send.
And then, I compile all files, put them on server, and then, send 1 command over MQTT to all devices.
When they wake up (most of them sleep and only wake up to perform measurements and send to home assistant, then they go to sleep again), MQTT command is waiting for them, once message is received each of them, one by one starts upgrade.
The devices that don't sleep, perform upgrade the moment the command is send.
-
- Posts: 71
- Joined: Sat Mar 02, 2019 8:06 pm
Re: Flash multiples ESP32 at the same time
As well, it's needed to keep some secrets on device, that's why secure boot and flash encryption are needed.
After you prepare your environment for factory files preparation, they are needed to flash on the modules.
For instance, if you don't want contract manufacture to have plain files with secrets, your company can prepare ESP32 modules before send to contract manufacture, and construct the tooling for batch flashing made of existing toolings for ESP32 modules.
You can generate NVS files with secrets with mfg_gen.py script and use the secrets from there
After you prepare your environment for factory files preparation, they are needed to flash on the modules.
For instance, if you don't want contract manufacture to have plain files with secrets, your company can prepare ESP32 modules before send to contract manufacture, and construct the tooling for batch flashing made of existing toolings for ESP32 modules.
You can generate NVS files with secrets with mfg_gen.py script and use the secrets from there
Who is online
Users browsing this forum: Baidu [Spider] and 334 guests