New "Game" - Terrarium: Flora

Glad I’m not alone :rofl: :joy:

BTW, you can now easily disable datagram support for your project as you are not using it:

1 - Create a “config” folder in the same dirtectory your sketch is.
2 - Create a “blinklib_config.h” inside this directory with the following contents:

#define BGA_CUSTOM_BLINKLIB_DISABLE_DATAGRAM

3 - That is it.

When you compile your program next time, you should get over 150 bytes of storage back and 200 bytes of RAM!

Let me know if it works for you.

1 Like

Doing some testing and thought I had everything squeezed within the code & data limits. Then I noticed that waking up tiles from deep sleep would put them into the dreaded 4-blink of death - meaning a stack overrun.

So I guess the code path to wake from deep sleep uses more local variables than any of my sketch’s code paths.

Just something to watch out for, I guess. Be sure to test sleep+wake for your games - both warm and deep.

I did some heavy data optimization (the code gets uglier the more I do) and believe I have freed up enough data space to fix this.

If I correctly read the code, at any point there are at most 8 bytes being used by the warm_sleep cycle thing. SO I guess you might be pretty tight with memory. Is this after disabling datagrams in the custom blinklib?

Is that 8 bytes on top of the user code? I thought I had more wiggle room than that.

Is this after disabling datagrams in the custom blinklib?

Oh yeah, I disabled datagrams a while back and burned through all the extra code and data space that freed up. Always working on the razor’s edge :wink:

1 Like

Well, 8 bytes on top of all global/static data in your code, but yes. It obviously does not count local variables in your code as whenever it enters the warm sleep loop, none of your code is being executed.

I am getting really curious with what you come up with in the end. :slight_smile: It better be good! :wink:

It better be good! :wink:

:open_mouth: :grinning: :sunglasses: