I’m am getting an SOS when I put my electron to sleep while connected to the cloud. I can find reference to the flash code 1 through 12. Anyone know what lucky 13 flashes signifies?
I get no error when going to sleep and never having connected to the cloud.
I believe it is a stack overflow. There are many ways to get this error I believe but, I often see it when an over the air update fails. I often clear this by refreshing the device using DFU mode.
Where did you find a list that ends with 12?
This is what I see
Thanks for the replies. It was stack overflow.
Found the error and fixed. Turns out I cannot call the sleep function from a timer. Moving the sleep function to the main loop solved the error.
I’m guessing that executing the sleep function from the timer causes issues in FreeRTOS. For now, I will just let the main loop be the state machine. Eventually, I really would prefer to get all the code out of the main loop and run everything off individual timers asynchronously.
Any suggestions on how to do that?
Sorry, don’t have the link off hand for the list that only goes to 12. Pretty sure I saw it on this forum, but lost the link when my IDE crashed.
Are you getting a red flashing LED after running your code on your Spark core? You may be getting a panic code, telling you what went wrong!
The panic code is a red LED blinking out SOS (… — …) followed by N flashes, followed by another SOS.
Here are the meanings of the N flashes, but #8, out of heap, is the most common:
#1 Hard fault
#2 Non-maskable interrupt fault
#3 Memory Manager fault
#4 Bus fault
#5 Usage fault
#6 Invalid length
#8 Out of heap memory
#9 SPI over-run
This is the thread with the codes only listed to 12.
Is there an official reference list in the official Particle documentation?
I fixed my post from several years ago to include 13 in case anyone else stumbles upon it.
Excellent! Thank you both very much.