-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Battery powered operation / deep sleep (was: Great Work) #24
Comments
check config.h |
Right now I don't have a clue when I will have the time to implement this feature. |
That sounds very advanced!
I was thinking of an easier (less detailed) way, really just waking up for
like 10 seconds, going to sleep for 300. 1.8.0/2.8.0 is good enough for my
use case, don't need much more
I am not famliar with yield().
Would a simple ESP.deepSleep(300e6); inside of void loop() do the trick already ?
Thanks for the reply!
…On Wed, Jun 2, 2021, 22:49 Michael Rüttgers ***@***.***> wrote:
Right now I don't have a clue when I will have the time to implement this
feature.
Configuring an interval won't help here, because the ESP8266 keeps running
and thus consuming energy.
Regarding the deep sleep feature I was thinking to switch over to the
ESP32, because the power consumption in deep sleep is less than the one of
the ESP8266 and because there is much more RTC memory available that could
be used during deep sleep to cache measurements before sending them batched
via wifi.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#24 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKYOFODQ7CDNMWRMYDCMVGLTQ2KNJANCNFSM452JHLPQ>
.
|
quick test only, seems it wasnt it. any pointers where to start ? |
It might work this way, but untested: But in order to make timer based wakeup work after putting the device into deepsleep you have to connect GPIO16/D0 to RST. |
Thank you. ` 2021-06-13 11:52:53 MQTT2_DEVICE MQTT2_esp8266_02A548 info: Hello from 0002A548, running SMLReader version 2.2.0. 2021-06-13 11:57:54 MQTT2_DEVICE MQTT2_esp8266_02A548 info: Hello from 0002A548, running SMLReader version 2.2.0. |
Sounds like the ESP ist going to sleep too fast. Try to add a delay before the sleep command in a non-blocking manner (short delays of i.e. 10ms together with a yield call within a loop). Somehow like this after the publish and before the sleep call:
|
Excellent, coming close. but will have to wait until tomorrow before I can bother the handyman for roomkey again. |
The wemos with powerbank via usb was (obviously) drawing to much power. |
In case it is still drawing too much power it might be an option to power the circuit with a LiFePO4 battery. Thus you can omit any LDO in between. In another project I'm running an ESP32 drawing about 10 μA in deep-sleep while directly connected to a LiFeP04 cell. With an LDO (and a LiPo cell, 3,7V) the circuit was drawing about 35 μA in deep-sleep. |
LiFePO4 would come by the cost of chargers etc. |
Ah, I see. |
that's a very nice device. I have to resist spending so much money ;) |
The first set of batteries (4x Varta industrial AA) lasted from 20.6-2.7. not as long as I hoped for. I might need to invest into something like power ranger. My poor man measurement (guess work, really) showed 140micro amps during sleep. |
That sounds like the LDO is drawing too much power during deep sleep. Edit: Ok, you said you don't use any LDO, so there might be another issue. Do you use a plain ESP8285 or a complete board? PS: I renamed the topic because other people might be interested in battery powered operation, too. |
WeMos lite. Batteries connected directly to 3.3. |
Hi I use a lipo for another Projekt on a wemo d1 mini. This ging to sleep for the maximum sleep time (I think, it was 30 Minutes). I use this setup for measuring a beehive with an hx711 and several temp Sensors,but the runtime is about a month with a 3,7v lipo. In did Not Do any solder magic. But there are several "China" stuff that contains a uart in it. This Part consumes the most currency, and that was my Prior fail into this. I am currently on my holdiay so that I can contribute only when I am at home. Maybe you can attach a Puffer battery like the lipo, a cn365 (Red one) Solar charger and a Solar cell. Then it can run nearly forever? |
Did you experiment with the wifi sleep modes? The following is my experience for the ESP32, but to my knowledge and according to a quick research this should mostly be true for the ESP8266 as well. There is WIFI_PS_MIN_MODEM, where the modem awakes every DTIM period and there is WIFI_PS_MAX_MODEM which sleeps longer (as configured). The latter one can cause issues with packet loss (which should be handled by the TCP layer) and in rare cases there are problems with some APs though I didn't had any issues with that. But even the MIN mode already decreases power usage quite a bit. The WiFiClient.setSleep* methods are usable for that. |
thanks for the code, it helped me to spot some strange electricity usage in my house.
any idea when the sleep mode will be implemented ?
my installation had to run on a power bank as there is no socket close to the meter.
I would be fine with one telegram every 300 seconds.
thanks !
The text was updated successfully, but these errors were encountered: