Skip to content

Latest commit

 

History

History
28 lines (25 loc) · 1.5 KB

README.md

File metadata and controls

28 lines (25 loc) · 1.5 KB

Stars Screensaver

A slightly blurry image of the star screensaver on an Arduino MEGA 2560, with a fps counter in the top left, but the screen is rotated 90 degrees counter-clockwise in the photo. (old photo with a lesser fps rate than with the sin lookup table)

Parts:

Setup:

  1. Attach the TFT to the top of the arduino
  2. Change your settings in settings.h
    • DEBUG: if you would like to compile debug Serial.prints
    • TFT_CS, TFT_DC & TFT_BL: if you use different ports for your lcd
    • TFT_BRIGHTNESS: 0-255 for the backlight strength
    • STAR_COUNT: if you would like more or less stars (32 stars gives a nice 52-58fps on my Arduino MEGA 2560)
    • STAR_MIN_SPEED & STAR_MAX_SPEED: for changing the speed of the stars in pixels per second (stars at the center travel at MIN speed and stars near the edge of the screen will travel at MAX speed)
    • SHOW_FPS: if you would like to see the fps count
    • FPS_UPDATE_INTERVAL: how many milliseconds should pass between updating the fps counter (to improve performance)
    • SHOW_MINMAX_FPS: if you would like to clearly see the min and max fps got (only takes effect if SHOW_FPS is 1)
  3. Upload the sketch
  4. See the stars fly by
  5. (don't keep it running for too long, since my Arduino starts to get warm)