IDF Boot Loader baud rate - can it be reduced ?

Synectix
Posts: 20
Joined: Mon Dec 14, 2020 6:13 am

IDF Boot Loader baud rate - can it be reduced ?

Postby Synectix » Wed Dec 23, 2020 12:11 pm

Hi,
The IDF Boot Loader with the USB to Serial Converter uses 460800 as the default baud rate.

Is it possible to use, say 112500 baud rate, instead of 460800 bauds, for downloading the image into the ESP32-WROOM-32E Module ?

The reason I ask this is because I have quite a few of our home grown RS232 to TTL Serial convertors and I was using one of them along with a standard USB to Serial Adapter to download the image into the flash. But, the max speed is 250kbps for my convertors.

So, is there a provision to change the 460800 o 115200 or will the ESP32 accept only 460800 baud data ?

username
Posts: 530
Joined: Thu May 03, 2018 1:18 pm

Re: IDF Boot Loader baud rate - can it be reduced ?

Postby username » Wed Dec 23, 2020 5:41 pm

You didn't say what environment your using whether Arduino or ESP-IDF.
I use ESP-IDF and you can change the upload speed via the idy.py
I.E. idf.py -p COM4 -b 921600 flash

I typically use 1152000 as my download rate.

Synectix
Posts: 20
Joined: Mon Dec 14, 2020 6:13 am

Re: IDF Boot Loader baud rate - can it be reduced ?

Postby Synectix » Thu Dec 24, 2020 11:24 am

Thanks !

I am using the "idf.py flash" command and tried the command "idf.py -p COM3 -b 115200 flash"

However, I am still unable to download into flash. The ESP32-WROOM-32E Module does not respond to the 'flash' command.

I am not using an Arduino or anything else. I made the ble-spp-client and ble-spp-server projects (available in the "examples/bluetooth/bluedroid/ble" folder on github) and wanted to download one of these into my WROOM-32E Module.

Do the EN and BOOT (IO0) pins need to be made hi/lo in any sequence for the 'flash' process to begin ?

Please note that I am not using any of the DEVKIT boards, but I have made my own breadboard, with just the Module, a robust power supply and the minimum required circuitry for TXD0, RXD0, EN and IO0 pins.

I can see the RXD0 pin receiving a proper 3.3V TTL data from the USB port of my laptop (USB to RS232 and then RS232 to TTL convertor) , but there is no response on the TXD0 pin of the ESP32 Module. Hence the idf.py times out with an error message.

Appreciate your inputs !
Thanks

username
Posts: 530
Joined: Thu May 03, 2018 1:18 pm

Re: IDF Boot Loader baud rate - can it be reduced ?

Postby username » Thu Dec 24, 2020 2:32 pm

Do the EN and BOOT (IO0) pins need to be made hi/lo in any sequence for the 'flash' process to begin ?
Absolutely. pull EN and IO0 low, then release EN, then release IO0. it will then be in programming mode.

Synectix
Posts: 20
Joined: Mon Dec 14, 2020 6:13 am

Re: IDF Boot Loader baud rate - can it be reduced ?

Postby Synectix » Fri Dec 25, 2020 11:35 am

Tried various combinations of pulling the EN & IO0 pins LOW and then HI as you had suggested, but to no avail !
I used a small PIC micro to manipulate these pins in different ways, with / without a delay...but, nothing helped.

In the "ESP32-WROOM-32E" datasheet, it says to keep IO0 and IO2 low to enter Download boot mode. But, in the ESP32-DEVKITC-V4 Schematic, the IO2 pin is not used and only the EN & IO0 pins are used.

So, a little confused !

In the ESP32 HARDWARE DESIGN GUIDELINES document, Section 4 says :
By default, the initial firmware has already been downloaded in the flash. If users need to re-download the firmware,
they should follow the steps below:
1. Set the module to UART Download mode by pulling IO0 (pulled up by default) and IO2 (pulled down by
default) low. The chip IOs are pulled down internally by default.
2. Power on the module and check through the serial terminal if the UART Download mode is enabled.
3. Download the firmware to flash, using the Flash Download Tool.
4. After downloading, pull IO0 high or just leave it floating and use the internal weak pull-up to enable the SPI
Boot mode.
5. Power on the module again. The chip will read and execute the firmware during initialization.
What is this initial firmware that is referred to here ?

Thanks !

Synectix
Posts: 20
Joined: Mon Dec 14, 2020 6:13 am

Re: IDF Boot Loader baud rate - can it be reduced ?

Postby Synectix » Fri Dec 25, 2020 11:58 am

Success !
I had to bring EN & IO0 low, then make EN high while keeping IO0 low.....and I could download the firmware into flash at 115200 baud :-)

Thanks for your help !

Who is online

Users browsing this forum: No registered users and 73 guests