Problems with FreeRTOS tasks and Light Sleep

GustavoGB
Posts: 18
Joined: Fri Jan 15, 2021 1:46 am

Problems with FreeRTOS tasks and Light Sleep

Postby GustavoGB » Mon Apr 05, 2021 3:34 pm

Hello, I would like to make a code where I can do a FreeRTOS "Task" that contains the action of Light Sleep (code taken from esp-idf light-sleep example).
I have problems with that because apparently when the system goes to sleep everything stops. FreeRTOS also seems to be stopped and does not work well, as the other tasks have problems.
Does this mean that I shouldn't use Light Sleep with FreeRTOS? Should I just do a sequential code?

Thanks a lot.

Gustavo

ESP_Sprite
Posts: 9769
Joined: Thu Nov 26, 2015 4:08 am

Re: Problems with FreeRTOS tasks and Light Sleep

Postby ESP_Sprite » Tue Apr 06, 2021 4:14 am

The entire idea of light sleep is to save power by shutting down the CPU cores, so yeah, you're not going to be able to run any code while the system is in light sleep. You can use Light Sleep with FreeRTOS, but you need to make sure that whatever you want the SoC to do can be initiated by a light sleep wakeup source.

GustavoGB
Posts: 18
Joined: Fri Jan 15, 2021 1:46 am

Re: Problems with FreeRTOS tasks and Light Sleep

Postby GustavoGB » Tue Apr 06, 2021 1:13 pm

ESP_Sprite wrote:
Tue Apr 06, 2021 4:14 am
The entire idea of light sleep is to save power by shutting down the CPU cores, so yeah, you're not going to be able to run any code while the system is in light sleep. You can use Light Sleep with FreeRTOS, but you need to make sure that whatever you want the SoC to do can be initiated by a light sleep wakeup source.
Thanks you, I think I knew but needed confirmation that it really was like that.

Greetings.

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 89 guests