GarfieldXBM: bitmap icons for small monochrome displays
The smallest repository on my GitHub is also the easiest to understand: GarfieldXBM is a handful of tiny monochrome bitmaps — a Garfield boot splash plus mute/speaker/nuclear icons — stored in XBM format for use on 128x64 OLED/LCD projects.
What is XBM?
XBM is one of the oldest image formats in the Unix world, and it has a superpower: an XBM
file is C source code. Each image is a static const uint8_t byte array,
one bit per pixel, plus _width and _height macros. That means
"drawing an image" on an Arduino is just "including a header and passing the array to the
display driver":
#include "Garfield.xbm"
display.drawXBM(31, 0, garfield_width, garfield_height, garfield_bits);
How the images were made
Each .xbm in the repository has a sibling .bmp — the source image
it was converted from. The workflow is: draw or find a 1-bit image, run it through an
image-to-XBM converter, and commit both files. Keeping the BMP next to the XBM means you can
re-convert at a different size or threshold later.
Who consumes these
BootSplashBitmapin ESP8266-Functions-Common draws the Garfield splash at boot (the array is copied in under the readable namegarfield, because auto-generated converter names likec0c2ac37ec5e…are unpleasant to type).- The Geiger counter uses the nuclear icon as a radiation-status indicator; the piano-humidity controller uses the mute and speaker icons for its sound state.
Beginner takeaway: little assets deserve their own repository. A single canonical place for icons beats five projects each containing a divergent copy.