Auto program Boot Flasher is still mysterious!
Posted: Tue May 15, 2018 6:21 pm
Hello all and thank you for reading.
I have searched and read all of the related internet posts regarding the ESP32 flashing mode which should be automatically entered using a usb serial interface on the development boards Rover and Dev Kit C.
Each of these boards employ a resistor / transistor bridge circuit from DTR and RTS to properly toggle the ESP32 EN and IO0.
While both of my development boards work just fine, I believe the logic to this circuit has some real mysteries and is not reliable.
I have build a board design with this exact circuit, as exampled in the dev kit schematics:
DTR -> 12Kohm -> Base Q1
RTS -> 12Kohm -> Base Q2
EN -> Collector Q1
IO0 -> Emitter Q2
Emitter Q1 -> RTS
Collecter Q2 -> DTR
There is a logic table provided in the schematic
Auto Program
DTR RTS -> EN IO0
1 1 1 1
0 0 1 1
1 0 0 1
0 1 1 0
OK, here is the MYSTERY!
My understanding to enter serial flash upload mode, IO0 is held low, EN is pulsed low, then IO0 is brought high.
This circuit does not allow for a DTR RTS combination which will pulse EN low while holding IO0 low.
My understanding of the required timing:
IO0 ''''''''''''''''\.........................../''''''''''''''''''''''''''
EN ''''''''''''''''''''''''''''''''''''''''''\...../'''''''''''''''''''''''''''''''''''''''''''
^ Serial Upload ready
The circuit does not allow for both IO0 and EN to be low at the same time.
I think it works because there is a capacitor on EN which my hold it low long enough to get the IO0 pulse coincident.
I have build 40 boards with this circuit using the 12K ohm and S8050 transistors as called out. I have 5Kohm pull down on IO2 and a 12Kohm pull up on EN.
On 40 boards, about 2/3 work from the USB, the reset need me to manually assist with the flasher BOOT / EN buttons which are also on my board design.
This flaky operation seems to be a result of the circuit design of the two transistors which make the low state for IO0 or EN mutually exclusive.
I am looking to make thousands of these boards for an internal IOT solution and would really like to solve this.
Thoughts?
I would really like to have a reliable USB serial flash connection, rather than the mystery ... -------.......------ error!
I have searched and read all of the related internet posts regarding the ESP32 flashing mode which should be automatically entered using a usb serial interface on the development boards Rover and Dev Kit C.
Each of these boards employ a resistor / transistor bridge circuit from DTR and RTS to properly toggle the ESP32 EN and IO0.
While both of my development boards work just fine, I believe the logic to this circuit has some real mysteries and is not reliable.
I have build a board design with this exact circuit, as exampled in the dev kit schematics:
DTR -> 12Kohm -> Base Q1
RTS -> 12Kohm -> Base Q2
EN -> Collector Q1
IO0 -> Emitter Q2
Emitter Q1 -> RTS
Collecter Q2 -> DTR
There is a logic table provided in the schematic
Auto Program
DTR RTS -> EN IO0
1 1 1 1
0 0 1 1
1 0 0 1
0 1 1 0
OK, here is the MYSTERY!
My understanding to enter serial flash upload mode, IO0 is held low, EN is pulsed low, then IO0 is brought high.
This circuit does not allow for a DTR RTS combination which will pulse EN low while holding IO0 low.
My understanding of the required timing:
IO0 ''''''''''''''''\.........................../''''''''''''''''''''''''''
EN ''''''''''''''''''''''''''''''''''''''''''\...../'''''''''''''''''''''''''''''''''''''''''''
^ Serial Upload ready
The circuit does not allow for both IO0 and EN to be low at the same time.
I think it works because there is a capacitor on EN which my hold it low long enough to get the IO0 pulse coincident.
I have build 40 boards with this circuit using the 12K ohm and S8050 transistors as called out. I have 5Kohm pull down on IO2 and a 12Kohm pull up on EN.
On 40 boards, about 2/3 work from the USB, the reset need me to manually assist with the flasher BOOT / EN buttons which are also on my board design.
This flaky operation seems to be a result of the circuit design of the two transistors which make the low state for IO0 or EN mutually exclusive.
I am looking to make thousands of these boards for an internal IOT solution and would really like to solve this.
Thoughts?
I would really like to have a reliable USB serial flash connection, rather than the mystery ... -------.......------ error!