Bitmap graphics on 16x2 text display using the LiquidCrystal library only

Hitachi HD44780 displays are meant for text only, but they have 8 user-defineable chars. One char is 5x8 pixels, and arranging the 8 of them in 4 rows and two columns gives a small 40x16 bitmap. Each pixel can then be turned on and off at will, supporting arbitrary graphics. Animation is possible, as long as it isn't too fast for the slow lcd.

I have a demo program here: It demonstrates three uses:

  • single-pixel bouncing ball
  • moving lines
  • sine wave plot

If your 16x2 display has buttons, then they can be used for switching demos and changing animation speed. If not, wait 15s for the display to change automatically.

The gaps between character cells cannot be used, this limits what it is possible to display. The bouncing ball only uses every other pixel, that way it doesn't need the missing ones.