Page 1 of 1

Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Tue Nov 28, 2017 11:32 am
by euquiq
Hello !

This is my first post ! Good to be here! I am an ESP32 / electronics enthusiast - hobbist, and my electronics knowledge is kind of meager, so please forgive me if my question is kind of basic knowledge.

I am trying to do a solar panel based experiment on an ESP32, with some solar panels which at peak sun deliver around 3.3volts.

If I hook it directly into the ESP32, at that moment, the ESP32 happily wakes up and executes its chores.

BUT, if I connect the solar panels at night, then sun arises and gradually powers up the ESP32, then it remains unresponsive. Most of the time it won't even revive when pressing the reset button on the board: I need to unhook the solar panels and reconnect (at good sun time) for the ESP32 to revive.

Then, as a second step I purchased a "cheap" 3.3v regulator, those that can be found on online stores carrying a description like "0.8v - 3v to 3.3v voltage step up regulator" and now my power "system" is comprised of:

Solar Panels -> Diode -> 2.7v supercapacitor -> 3.3v tep up - regulator -> ESP32

I manage to get about 3.3v way earlier on the morning, and in general, get stability for most of the sunlight period, since my code makes the ESP32 go to sleep and only wakes up to perform a sensor reading for less than a second.

BUT AGAIN: at first, when the voltage is low, and the step-up regulator cannot quite start delivering 3.3v, slowly ramping into that voltage line, will freeze the ESP32.

So I was wondering if anyone got any insights on this behavior, if it is to be expected.

I am thinking about placing a transistor which could open up voltage input into the regulator when it senses that the supercapacitor reached a viable source voltage (around 1.4 volts as I could test, instead the "advertised" 0.8 volts from the step-up / regulator).

Any idea, help or comment, please, I would appreciate it very much.

Regards, Enrique.

Re: Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Tue Dec 05, 2017 2:26 pm
by photomankc
I'm far from an expert on this chip, but in general, that is a situation to avoid with digital electronics. Operating them in the no-mans-land of 1 or 2 volts can cause a lot of unwanted behavior. Most regulators need a certain level of voltage to provide regulation. Below that they simply follow the rising/falling voltage at some offset.

You would probably be best served to power the system from some kind of battery pack, and use the solar output to recharge that battery in the daytime. This would isolate your circuit from the glacial-paced rising/falling slope of voltage from the solar panels at dawn/dusk and provide a far more stable voltage range that would allow you to select a useful regulator to provide the needed 3.3V output.

Re: Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Sun Aug 12, 2018 8:59 pm
by tommeyers
My experience with a similar configuration is the same.

BOD and BOR don't seem to be working the way we expect.

I have v1 of wroom. BOD/BOR was to have been fixed in v1; was it?

Can we get an explanation of the cause.

Thanks, Tom

Re: Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Sun Aug 12, 2018 9:08 pm
by urbanze
Same experience here. When I raise the voltage slowly, with or without BOD, mcu is locked and never initializes until the restart is forced. What is this, why does it occur and how do I fix it?

Re: Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Mon Aug 13, 2018 2:27 am
by ESP_Sprite
The issue with the BOR is that it's not enabled on reset.... the thing is that it's mostly designed as a safeguard against power sources not being able to deliver enough current; in that case it will disable WiFi and reboot. The problem mainly is that it's not enabled after a reset, so there is a short period between a BOR reset and the software restarting and the BOR being re-enabled where a hang can occur. This is unfortunate, but it makes the BOR unusable for the purpose you have, and in this situation we would recommend an external voltage monitor to reset the ESP32.

Re: Slow ramping voltage hangs esp32 / BOR - Brownout misbehavior or not ?

Posted: Mon Aug 13, 2018 3:57 pm
by tommeyers
Thanks.

What is the brownout process when the esp32 is in deep sleep?

flow1: deepsleep--------------------------------------------awake (timer)
^
|
----------Brownout
flow2: running-------
^
|
----------Brownout

It appears that my problem occurs when I have a brownout during deep sleep: I don't wake and I can't reset.

Solution cannot be a reset because it doesn't work.

I have a solar/battery power system at 3.3v. I deepsleep to save power. I want to wake/run at the timer-end (that would be without a brownout during deepsleep) or run with restart (brownout during non-deepsleep or deepsleep) when the power returns.

This seems like a usual protcol for solar powered processors with brownout detection and recovery; correct?

Tom