Tips for using sleep modes / save power
Posted: Fri Aug 14, 2020 2:52 pm
Hey there,
this is my first post about my first ESP8266 project, so bear with me I am a software engineer, but never ended up doing some micro controller programming. Now with doing more and more home automation, I also started making devices smart, which are not close to be smart
Like my doorbell, which is the project I have a question about
First, the code: https://github.com/gman-php/esp8266-ske ... orbell.ino
I live in a pretty new apartment in Germany and I have one of these doorbell phones most people have. Luckily, it has an interface to connect external signals / doorbells, so that's where you can capture the doorbell signal. It's simply sending a 5V signal on one contact if somebody is ringing the doorbell.
So the whole code and the project / hardware wiring works. No problem, everything cool
My question is about power consumption. Unfortunately, I have no power source near the phone and the phone itself really doesn't like it when you steal from it's 24V output, pull it down to 5V and connect it to the ESP. For some reason, you get a huge noise on the phone, even with capacitors. So I need to live with a battery pack (for now!).
But as you know, power consumption is pretty high, but there are sleep modes. I was reading through them a bit, but didn't 100% understand how they work and if I can make use of them.
Why I think I can't use them? Because I have a case where the ESP needs to check for a signal on GPIO4 all the time, because somebody could ring the door. I don't know when this will happen. So I always need to plan with it.
And it seems that in every sleep mode, it also looses the Wi-Fi and MQTT connection!? So even if I do 1 second modem/light/deep sleep, I will still then need to go through Wi-Fi and MQTT connection before I can inform my Home Assistant (HA) about the poor person, standing out there in the rain ringing the doorbell, probably seconds ago!?
So I'm asking straightforward: Do you see any chance for using any sleep mode in my use case and also having a few hints/links/example code lines showing how to use them? I can live with around 1-3 seconds of total delay for the doorbell signal to reach my HA. But I think more than that is a bit long.
Thank you so much already and greetings,
Andy!
this is my first post about my first ESP8266 project, so bear with me I am a software engineer, but never ended up doing some micro controller programming. Now with doing more and more home automation, I also started making devices smart, which are not close to be smart
Like my doorbell, which is the project I have a question about
First, the code: https://github.com/gman-php/esp8266-ske ... orbell.ino
I live in a pretty new apartment in Germany and I have one of these doorbell phones most people have. Luckily, it has an interface to connect external signals / doorbells, so that's where you can capture the doorbell signal. It's simply sending a 5V signal on one contact if somebody is ringing the doorbell.
So the whole code and the project / hardware wiring works. No problem, everything cool
My question is about power consumption. Unfortunately, I have no power source near the phone and the phone itself really doesn't like it when you steal from it's 24V output, pull it down to 5V and connect it to the ESP. For some reason, you get a huge noise on the phone, even with capacitors. So I need to live with a battery pack (for now!).
But as you know, power consumption is pretty high, but there are sleep modes. I was reading through them a bit, but didn't 100% understand how they work and if I can make use of them.
Why I think I can't use them? Because I have a case where the ESP needs to check for a signal on GPIO4 all the time, because somebody could ring the door. I don't know when this will happen. So I always need to plan with it.
And it seems that in every sleep mode, it also looses the Wi-Fi and MQTT connection!? So even if I do 1 second modem/light/deep sleep, I will still then need to go through Wi-Fi and MQTT connection before I can inform my Home Assistant (HA) about the poor person, standing out there in the rain ringing the doorbell, probably seconds ago!?
So I'm asking straightforward: Do you see any chance for using any sleep mode in my use case and also having a few hints/links/example code lines showing how to use them? I can live with around 1-3 seconds of total delay for the doorbell signal to reach my HA. But I think more than that is a bit long.
Thank you so much already and greetings,
Andy!