Page 1 of 1

esp32 sleep mode with relays

Posted: Tue Aug 30, 2022 2:47 pm
by Pia012
Hi everyone, this is the first time that I write on this forum and I don't know if I should introduce myself. Let me know if I should do it. However I am developing an IOT architecture where I am using the Esp32 board and some sensors and relays.

Image
I tried to show it without linking the GPIO channels.

I have 3 sensors that each 4 hours send their values to a WEB server, because I would monitor the water values. I thought to use the board deep sleep mode waking up it each 4 hours with a timer RTC. Summarize, the board gets some values each 4 hours , it sends them to a WEB server and looking over this values decides to change the state of relay to turn on or to turn off the related accessories. The problem is that when the board goes to sleep, it turns off all the relays and all the related accessories linked turn off. Can I hundle the relays states also when the Esp32 is sleeping? I don't know, can I get the relay module indipendent from all keeping all their states that the board will change based on the situation?

Re: esp32 sleep mode with relays

Posted: Wed Aug 31, 2022 1:02 am
by ESP_Sprite
Yes, you can. However, given the relay hold current and the OLED and stuff that's connected, I'm not sure if deep sleep would be that useful... I'd personally keep the ESP32 alive so it can read out the sensors a bit more often and update the OLED accordingly.

Re: esp32 sleep mode with relays

Posted: Wed Aug 31, 2022 9:26 am
by Pia012
Thanks for your answer, so do you think that I could gain only a bit of power with sleep mode because every modules have their Power source?

Re: esp32 sleep mode with relays

Posted: Thu Sep 01, 2022 12:48 am
by ESP_Sprite
Exactly. As an indication: a single relay uses somewhere from 40 to 90mA when it's turned on, which is in the same order of magnitude as an idle ESP32 uses.

Re: esp32 sleep mode with relays

Posted: Fri Sep 02, 2022 4:28 pm
by Pia012
Ok, thanks for your answers.