Flash ESP-12F with Webos D1 mini

Hello,
would it be posible to flash an ESP-12F with a D1 Mini? I know that it's posible with a NodeMCU board:

But the D1 Mini doesn't have the pin EN to disable the controller.
I have read somewhere that should be posible to do it just wiring the other pins the same way, as they are the same chip, but both boards would be flashed at the same time.
Would it be posible and safe?
Thank you!

2 Likes

wemos d1 has a reset pin. wire it to ground to hold the onboard esp in reset

1 Like

Ok, but then I can't connect the reset pin of the D1 mini to the ESP-12F.

What I could do is to put a push button in the reset pin of the ESP-12F to be able to reboot it. When starting to flash I should push the button. So, a push button between RST and GND should work, right?

And maybe I could add also a switch button in GPO0 to move from flashing boot mode to normal.

I'm not sure if this would work, I could try if it is safe for the chips.

put the esp-12F into flashing mode any time before upload. it stays in it until next reset.

Ok, thank you, I will try it with different options. The idea would be something like this:

Maybe I should connect the GPIO0 to GND, to force that it boats always in flash mode. Otherwise, if I understand it right, the D1 nano board would put the GPIO0 to 0 when I click on "upload" in the IDE, not before, but couldn't send the reset as it is connected to GND.
I'll try with different options.
Thanks!

Today I connected everything and did some tests. It worked somehow with but the result it's not completely clear to me.

First I tried with the mentioned configuration.
It didn't work. The arduino IDE was unable to connect to flash. I was trying to click on reset when the flashing starts but probably I didn't hit the right moment. Maybe I should use two buttons to pull down both pins and make sure that the ESP-12F boots in flashing mode.

Then I tried connecting the RST pin of the D1 Mini directly to the RST pin of the ESP-12F.

This way it worked, but flashed only the ESP-12F !!!
I uploaded the 'Blink' program and only the ESP-12F led started blinking. I don't know why this happens, I expected that both boards would be flashed at the same time.

Then I disconnected both RST pins and flashed again. This time only the D1 Mini was flashed. I put different blinking times to make sure that the ESP-12F was not flashed.

So, connecting all the involved pins directly seems to work, at least with the couple of tests that I did.
I'm not sure if this is safe, the D1 mini is supposed to be up and running while flashing the ESP-12F and sharing all the pins and signals.

It seems to me a convenient way to flash the ESP-12. I don't need the USB TTL adapter and the second power source to provide the 3.3v or other complex boards. I can setup a small protoboard as a dedicated flashing board.

1 Like
  1. there is communication in both ways while flashing so both can't be flashed

  2. you can reset the esp with io 0 low any time before flashing. you don't have to catch the moment of upload.

Yes, but so far I have put only a button in the reset pin. I could put another button or better a switch in the GPIO0.
Then I would put the switch in 'flashing' position (GPIO0 down), click on the reset button and then flash, right?
Afterwards I put the switch back to normal mode (GPIO0 floating) and restart in normal mode.

Thanks!

Ok, the last configuration seems to work fine. This would be the process:

  • Flash mode:

    1. Move the switch to the left (GPIO0 to GND).
    2. Press the reset button.
    3. Click on upload in the IDE program in the computer to flash the ESP-12F.
  • Normal mode:

    1. Move the switch to the right position (GPIO0 floating) and reset => ESP-12F boats in normal mode and runs the code.

Any suggestions or advices are welcome!

it is good to upload once, not to do development.
for updates use OTA update

Yes, you are right, it's better to use it only for the first upload. Otherwise wiring it all back to reflash could be a pain.
Anyway I think that after connecting a new ESP-12 board for the 1st time, could better to do a quick test with the 'blink' program to make sure that everything works, and then flash the final program.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.