I could not easily find the information I was after, most likely because I am still learning all this but would love some advice to achieve a board setup with deep sleep.
At the moment I am really enjoying this ecosystem and am using a RAK19007 board and have incorporated the RAK12500 (GPS) and RAK5860 (Modem). I am currently also using a RAK11200 (ESP) core but not sure if that is the way to go. I have everything working at the moment but I want to put the unit into a deep sleep only to be waken by a timer or an interrupt. I just got the RAK1905 accelerometer to do the wakeup but can change that if needed.
What I could not easily find was how to wake up the ESP from a deep sleep using either a timer or an interrupt (preferably from the RAK1905). I assume the ESP does not have an RTC on board so I would have to get it as another module?
I also saw some posts that maybe the Arduino variants are not the best for this? I am also open to changing to a different core like the RAK4631 or RAK3372.
Anyway, hopefully that makes some sense and if anyone has any guidance to a board combination setup with those sensor modules where I can deep sleep the core that would be great. Sorry I should add that I also power off the other sensor modules by turning their pins to low (WB_IO1/2/3 etc).
If you don’t need WiFi, I would go for the RAK4631 (LoRa + BLE) which has a much lower power consumption or, if your application is not too large, for the RAK3172 (RUI3 API, slightly different for Arduino BSP’s) which is the lowest power consumption module we have.
So I had a look at your code @beegee and am sleeping the ESP in the same way you are. I also got the RAK1905 to wake the device on movement which is great.
However, I noticed when I go into deep sleep it is consuming about 3.2mA.
I did some isolation testing (after spending a few days on my code thinking that might be the issue) and found the following results. I made a basic program that does nothing but turn the Blue LED on and off 4 times then puts the unit into deep sleep. I include no other libraries and do not touch or interact with any other pins. I found the following results of power consumption in deep sleep:
Why is the ESP32 on its own reporting 10 times the amount of current draw from the tech docs, from everything I have read, deep sleep should be around 10uA?
Why is the RAK1905 consuming 2.7mA without even being used? And again this is after calling the ESP deep sleep.
Would you have any idea why the power consumption seems to be this high?