Skip to content

Instantly share code, notes, and snippets.

View pkamp3's full-sized avatar

Paul Kamp pkamp3

View GitHub Profile
@pkamp3
pkamp3 / bitmap2bytemap.py
Created May 25, 2017 08:00
Fonts and string creator for Hackpack v3
"""
Convert IMAGE based fonts to uint16_t.
Code to convert BITMAP or IMAGE based fonts to fonts
for use on the 2017 SIGNAL Hackpack. Characters must be in the form of 4x4
pixels. Please pad smaller fonts to 4x4 pixel blocks.
By convention, it should be in ASCII order and start with the 'space'
character: http://www.asciitable.com/ (see the example png)
Install PIL or PILLOW (perhaps 'pip install pillow'?) and run with:
@pkamp3
pkamp3 / animated_gif_converter.py
Last active May 24, 2017 23:40
Animated gif and movie converter for Hackpackv3
"""
Convert animated gifs to uint_32t encoded colors for use on the Hackpackv3.
Got a Hackpackv3? Here's an easy way to convert animated gifs or
movies into encoded 4x4 images; you can directly use this in the .ino
file to overwrite the 'custom_animation_lut'
Sample use (bash example, change for your platform):