0

Set ESP32 WiFi to sleep and wake up when it receives message
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Set ESP32 WiFi to sleep and wake up when it receives message

by xbr on Sat Feb 27, 2021 12:28 pm

So, as per the title, the basic question is: Can I put my ESP32's WiFi connection to sleep and wake it up when sending a message to it through WiFi? Or is it, as I suspect, by definition impossible to wake it up through the service that you've put to sleep? Is the only way of achieving this to set the sleep mode to intermittently sleep and connect every so often to check if there're any messages?

I've searched all over the place and haven't found exactly what I'm looking for, so I'm not sure if I haven't found the right source or if it's just something that can't be done.

I have an LED light that I configure through and app I made for my phone. Currently I'm using WiFi, though I want to implement the same function through BT later, as I think it will be less power-hungry. But, for the time being, I want to see if I can make the project a little less power-hungry, as in any case one will only configure the light once or maybe twice a day, so having it constantly connecting through WiFi, looking for any kind of communication, doesn't make too much sense. (I've also noticed the module runs warm, which it really shouldn't with the small load it has.)

So, aside from the main question, I'm also not sure which is the "deepest" sleep mode I can get away with if I'm only using one pin to send data packets to a WS2812b LED strip, and that has to continue working, and all I want is to set the WiFi to sleep when it's not needed (which is what I think is warming up the module and by being constantly working).

xbr
 
Posts: 8
Joined: Thu Feb 11, 2021 7:32 pm

Please be positive and constructive with your questions and comments.