@happyuser said in M5Dial generate interrupt from RTC?:
I assume your conclusion is then also : no wake-up with RTC interrupt?
Uhm no, or yes.... maybe.... depending of how you define "wake-up"🤔 ☺️
When Q3 goes on the hole board including the ESP32 is switched on so in my book the RTC can "wake up" the hole board. Of course you could say that this is more like "switching on" than "waking up".
But in fact, when ESP32 is in its "native" deep-sleep the main CPU is also effectively switched off which means it needs to boot completely from scratch when it "wakes up" from that state. Now, it is correct that there are some build in features to test for the reason of the boot and then have the program act on that, but that is actually also possible with the circuit M5Stack built. There is a signal called "wake" connected to GPIO42 which will indicate for the ESP32 whether it was started by the push button (S1) or by the INT signal from the RTC chip.
I can only speculate in why M5Stack has chosen not to use the build in ESP32 RTC/deep sleep functionality but here is two reasons:
If the board as a hole needs to have a very low power consumption in (deep)sleep mode it is not enough to just have ESP sleep there are other chips or circuits that may still consume "a lot" just by having Vcc applied. So you need the MOSFET switches any way for a "good sleeping" board and
the BM8563 seems to consume less than the ESP32 built-in RTC about ~2-3µA vs 10µA
In this testing environment I wired it to the 3.3 volt output of the Stamp. Not the best solution, ha ha, given the power the SIM7080 module needs. I am now converting it to powering the SIM7080 module with separate 5 volt line.
That should do the trick.
Hello @HappyUser
it is correct that M5StampC3 is supported by M5Unified library, but I can confirm that the library currently doesn't compile due to errors in Mic_Class.cpp and Power_Class.cpp.
I suspect that since there isn't much to gain from using a library like M5Unified for a stamp product (as @teastain already mentioned), M5Stack engineers aren't that alert in keeping the library updated.
Thanks
Felix
@felmue And indeed, I needed to add a delay before sending the payload. I had hoped that it would be necessary (in order to speed up he process of waking up, sending and going to sleep).
Regards
Thanks,
Indeed,
This works :
display.drawJpg(JPG_buffer_processed, Append_this_Struct.JPG_size, 0, 0, Append_this_Struct.JPG_width,Append_this_Struct.JPG_height,0,0,JPEG_DIV_2);
@felmue Thank you. Unfortunately currently I am using the other SIM7060 module. Well, I could power it down with an optocoupler or something like that. Maybe a good idea in future modules to incorporate the deep sleep logic.