While working on another project (http://arduino.cc/forum/index.php/topic,55044.0.html, I’ve been looking for a way to get an image and HTML code into the Arduino sketch (NOT on a SD-card) with the minimal use of SRAM and I pulled it off.
You can read about this project on my website: http://www.jo3ri.be/arduino/arduino-projects/an-integrated-webpage-with-image and the blog I wrote about it: http://www.jo3ri.be/arduino/blogduino/usinglesssramonthearduino
This is the result:
The original GIF image with 32 colours is about 7884 bytes, but we are using a buffer of only 250 bytes. The image has been divided in 8 smaller images of approximately 1K. Those smaller images are being put next to each other when the client request the page. Now each image has been put in an array of 8 (again). The buffer has to be as big as the longest prog_char + 1, but I have put about 10 bytes more in the buffer (250 bytes).
Now If you’re smart, you can even reduce Flash memory, when you have a picture with repeating parts in it.
I hope this is helpful for al those people using a webpage for there Adduino projects with buttons and other small images.
The sketch is on my project page, but I have attached here too.
webimage.pde (21.1 KB)