How to not run boot.py?

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
heikki.hietala
Posts: 8
Joined: Thu Oct 11, 2018 4:52 pm

How to not run boot.py?

Post by heikki.hietala » Fri Oct 12, 2018 11:47 am

Hello,

I have a project that works just fine, is connected to the Internet and all, but now I'd need to change the program running on the device.

When I try to connect to it on PuTTY, I see this:

ets Jun 8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x2 (DOWNLOAD_BOOT(UART0/UART1/SDIO_REI_FEO_V2))
waiting for download

I suppose this is because it has already started to run the application on the ESP32. I can reflash it using esptool, but even after that I get the same message.

Is there a way to power up the device and not run the boot.py and correspondingly the main app?

Many thanks!

-h.

User avatar
Roberthh
Posts: 1046
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: How to not run boot.py?

Post by Roberthh » Fri Oct 12, 2018 11:50 am

What you see is the built-in bootloader of the ESP32 chip, which starts when at Power-up or reset GPIO0 is connected to GND or at low level. So please check the GPIO0 connection. This is nothing which can be changed by the MicroPython firmware.

heikki.hietala
Posts: 8
Joined: Thu Oct 11, 2018 4:52 pm

Re: How to not run boot.py?

Post by heikki.hietala » Fri Oct 12, 2018 1:18 pm

Ah - how wrong a n00bie can be. Many thanks for clarifying this to me.

As it happens, I don't have anything riding on GPI0 but I have a LCD, a buzzer and HCSR04 ultrasound sensor attached.

So, as I understand it, I should connect the GPI0 to the 3.3V if I want access to the board now?

User avatar
Roberthh
Posts: 1046
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: How to not run boot.py?

Post by Roberthh » Fri Oct 12, 2018 1:24 pm

The ESP32 has an internal pull-up for GPIO0. That ensures proper operation if it is left floating. So I guess you have something connected to GPIO0 which pulls it low. Please check your wiring.

User avatar
Roberthh
Posts: 1046
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: How to not run boot.py?

Post by Roberthh » Fri Oct 12, 2018 1:29 pm

Depending on the board it might be control line setting of PuTTY. Set PuTTY to Flow control = None.
It is under Confguration->Connection->Serial->Flow Control

heikki.hietala
Posts: 8
Joined: Thu Oct 11, 2018 4:52 pm

Re: How to not run boot.py?

Post by heikki.hietala » Fri Oct 12, 2018 2:00 pm

Thanks again! This board is very speedy and informative.

heikki.hietala
Posts: 8
Joined: Thu Oct 11, 2018 4:52 pm

Re: How to not run boot.py?

Post by heikki.hietala » Sat Oct 13, 2018 9:20 am

Hello Robert,

I double-checked and yes indeed, I have the ultrasound sensor's echo pin as GPI0. I guess moving it to some other pin will help me with this.

Thank you very much for the reply, I would have lost my remaining hair trying to figure this out by myself.

Heikki

HermannSW
Posts: 64
Joined: Wed Nov 01, 2017 7:46 am
Contact:

Re: How to not run boot.py?

Post by HermannSW » Sun Oct 14, 2018 10:20 pm

heikki.hietala wrote:
Sat Oct 13, 2018 9:20 am
I double-checked and yes indeed, I have the ultrasound sensor's echo pin as GPI0. I guess moving it to some other pin will help me with this.
I had similar situation (servo signal line connected to GPIO0) and did a different solution. Instead of moving to a different pin I soldered a small button between GPIO0 and VCC. That way I can press the button during powering the ESP and then release it:
https://www.esp8266.com/viewtopic.php?f ... 515#p78398

heikki.hietala
Posts: 8
Joined: Thu Oct 11, 2018 4:52 pm

Re: How to not run boot.py?

Post by heikki.hietala » Mon Oct 15, 2018 5:57 am

Thanks Hermann, it occurred to me too. This device will be located a little far from me and won't be reprogrammed, so I will just change pins, but keep that in mind for future devices.

Post Reply