Higher stack usage when returning from deep sleep?

Hey @bigjosh.

I am doing some changes to Hexxagon that makes it more memory (Arduino reports 128 bytes available for local variables, which I hope would be enough). Under most circumstances, this is not an issue. The game plays fine. I can get in and out of warm sleep without issues.

But when the Blinks go to deep sleep and I wake them up, they immediately start flashing 4 times in red (so, stack overflow, right?). This leads me to think that BlinkBIOS is doing something that uses more memory than usual when returning from deep sleep (BlinkLib does not seem to be the culprit).

Any ideas about what is going on? Is it possible to change/fix this so it would not use as much memory (in case my guess is correct, that is).


1 Like

Just chiming in that I, too, have seen this with Terrarium. Would love for the warm/deep sleep/wake routines to not be the critical path.

1 Like