we found that the only option to run on battery is to go to deep-sleep as often as possible. If your use-case is different, let us know, and I can see if we should expose the power-management functions.
inneos04/18/2025 08:35 AM
Yes, we go to deep-sleep as often as possible, but when using esp-idf framework, we also enable pm to save few more milliamps when esp is running
floitsch04/18/2025 08:38 AM
We are basically talking about the esp_pm_configure function. Right? So if I add a pm_configure max_freq_mhz min_freq_mhz light_sleep_enable function that would be enough. Or do you need more of the API?
inneos05/02/2025 09:44 AM
Yes, this would be great. I also use the esp_pm_lock_* api functions to prevent entering light sleep, but for now I could simply use esp_pm_configure to disable automatic light sleep when needed.
OPinneos
Yes, this would be great. I also use the esp_pm_lock_* api functions to prevent entering light sleep, but for now I could simply use esp_pm_configure to disable automatic light...
floitsch05/02/2025 10:25 AM
I will try to find some time to expose the functions then. Feel free to ping me from time to time
inneos05/02/2025 10:39 AM
Thanks a lot!
floitsch05/06/2025 05:27 PM
I just wrote a PR that exposes the config functions.
floitsch05/06/2025 05:30 PM
Adding support for the locks is also relatively easy, but would take me a few minutes. For now I will leave it unimplemented, but ping us, if you start needing it.
inneos05/07/2025 07:11 AM
Great, thanks a lot! I will try probably next week and report back here.
floitsch05/07/2025 08:38 AM
Couldn't resist... Now also added support for the lock class. All still under review, but I hope it will be committed today and that we will do a new release soon.