Bitmap Slideshow

Views: 1684 Difficulty: 3 Status: Development

Use the Joy Gamer to make a dynamic picture frame.

Make a palm-sized slideshow of your favorite moments! The JoyGamer has an on-board SD Card allowing you to store thousands of bitmaps for your viewing pleasure. This tutorial supplies code and examples to make your own dynamic picture frame.

Slideshow times 2

See bitmaps on oyur Joy Gamer!

JoyGamer Bitmap Slideshow Arduino Code

This code expects a bunch of bitmap files in the root directory of an SD card named exp0.bmp, exp1.bmp, up to exp[num_pics].bmp. You can create these files using our bitmap converter tool. In the main loop a random number between 0 and num_pics is chosen then we construct the filename correponding to this image in the line:
 pic_name = base_name + cur_pic + String(".bmp");
We display that image wait 3 seconds and do it again. All the necessary libraries can be downloaded from our main Joy Gamer Tutorial.
/* LucidTronix Joy Gamer SD Navigator
 * If the compiler gives you an error about sketch being too big make sure to
 * COMMENT OUT both the USE_ACCELEROMETER and the USE COLOR defines in the JoyGamer.h file.  
 * They should look like this:
 //#define USE_COLOR
 * For more instructions, details and schematic, See:

#include <JoyGamer.h>
#include <Adafruit_GFX.h>    // Core graphics library
#include <Adafruit_ST7735.h> // Hardware-specific library
#include <SPI.h>
#include <Color.h>

#include <SD.h>

// for leo:
Adafruit_ST7735  tft = Adafruit_ST7735(SS, 9, 8);
//for uno etc.. 
//Adafruit_ST7735 tft = ST7735(10, 9, 8);
// for mega
//Adafruit_ST7735 tft = ST7735(53, 9, 8);

JoyGamer jg = JoyGamer(&tft);

int cur_pic = 0;
const int num_pics = 19;
String base_name = "exp";
String pic_name = base_name + "2.bmp";
void setup(){

void loop() {
 cur_pic = random(0, num_pics);
 pic_name = base_name + cur_pic + String(".bmp");
Mixing pixels from two face images together....
Print bitmaps, cellular automata, drawings and text.....
An open source bitmap converter program built with Open Frameworks...
Display bitmap images and text files and folders with this TFT LCD screen and SD Card navigator....
Arduino-powered spherical camera with 2 Servo Motors and an SD Card....
Servo motor, JPEG camera, and Arduino Leonardo combine to make a panoramic camera....
Handheld gaming machine, based on the Arduino Leonardo, equipped with joystick, SD card and more....
Our take on the classic bouncing ball, paddle game....