I seem to be running up against a memory limitation of some sort while working with bitmap animations packed into literal arrays. I am using this python script that Pixie posted to generate the Pixelblaze code for my image arrays. My images are 32 pixels by 23 pixels, and so far I have only been able to successfully load/preview/run a 3-frame animation (3 frames of a 32x23 bitmap). It runs well and looks great!
However as soon as I paste the additional code into the editor with the array for the 4th frame, the editor freezes up. I’ve tried over 20 times now, power cycling the PB and deleting the previous pattern attempt from memory in between each try. Generally it freezes while trying to generate the preview, and so it never previews or runs or gives me a chance to hit the Save button (and then I have to power cycle to unfreeze the editor). Occasionally it will allow me to try to hit the Save button after adding the the full 4 frame code, but then it will throw an error in the middle of the save process. I have however once or twice managed to get it to save the code for all 4 frames, but as soon as I try to activate the pattern it then freezes while trying to run/preview it. So I get various behaviors from the UI, but the end result is the same in all cases: it cannot run the full 4-frame code. The 3-frame code works perfectly however, and the only difference between the two is addition of the extra arrays holding the 4th frame of the bitmap. So I’m guessing somewhere between frame 3 and frame 4 I am hitting a memory limitation? How would one analyze/determine that? (As an aside, my pattern list page says I have 600K free, and the text for this code is only 166K. So to me that suggests I’m not dealing with a storage issue, but rather hitting a memory limitation when the code is being executed.)
Here is a Pastebin link to the full 4-frame code (was too big to paste as a code snippet): https://pastebin.com/rZ2PNqL4