I have a fairly simply application that runs the system in the background thread and wakes up for two hours twice per day. My application is running ok on v0.9.0. I recently upgraded a few devices to 1.1.0-rc-1 and I am able to reproduce assertion error on most Argons and Xenons running the OS version with my application.
Steps to reproduce:
System is up and connected
LED pulses cyan
Request Sleep (remote function or button triggered)
You are using stop sleep which will pick up action after wake in the next line following the sleep call. Consequently your code would immediately enter sleep again since you don't reset your sleep flag.
While this should still not cause an Assertion Failure panic it's definetly a flaw in the logic.
You should first flash a 0.9.0 targetted application and I'd rather flash the system part1 binary than hybrid.
I confirm that this assertion failure error happens also on Boron LTE, firmware 1.1.0.rc-1
Reverting back to 0.9.0 makes the issue go away. @schooltag you can open an issue on github or I can do it on your behalf.
Good point @ScruffR . My main application does exactly as you speak, I just pulled out this flawed excerpt and never noticed the problem because I reproduced the SOS. The code demonstrated what was intended, but you are a good community debugger indeed.
Thanks also for the application flashback tip. Will do.