|
pico-ssd1306
0.1
Simple library for using ssd1306 displays with the Raspberry Pi Pico and the pico-sdk.
|
Simple library for using ssd1306 displays with the Raspberry Pi Pico and the pico-sdk.
ssd1306.h and examplePICO_SDK_PATHexamplemkdir build && cd build && cmake .. && makessd1306-example.uf2 to your PicoThe library can draw monochrome bitmaps using the functions ssd1306_bmp_show_image and ssd1306_bmp_show_image_with_offset.
For converting an image to the supported format, you can do the following:
convert you_image.png -monochrome your_image.bmpFor embedding your image, you can use tools like bin2c (included in the hxtools package on Debian).
Alternatively, you can you the version included in this repo:
make./bin2c your_image.bmp your_image.hYou may also take a look at the example in the example/ directory.
You can also use or own fonts when drawing with ssd1306_draw_char_with_font or ssd1306_draw_string_with_font. The format is:
uint8_t values, when the height is greater than 8; please look at font.h and the fonts in the example/ directory