Here’s a study in sprite animations that [Travis Goodspeed] put together. He’s working with one of his favorites, the pink IM-ME device that he’s been hacking on for a while now. But if you don’t have this hardware that shouldn’t discourage you. There’s a lot to be learned from his methods which will translate to any microcontroller working with a graphic LCD.
He starts with a 24-bit PNM sprite that includes three frames of his desired animation. From there he needs a way to store the data for use with 8-bit microcontrollers. He chose to write a Perl script that will translate the image format into a 1-bit map. Each frame of the animation takes up a column width that is a multiple of 8 for easy retrieval by the processor. This translation into a C array, and the accompanying code that translates it into data for the frame buffer is the key to the animation process. What is he shooting for? A sprite-based video game on the handheld.