All fonts render garbage
amyspark opened this issue · comments
Describe the bug
With current master, all fonts render garbage in my toy clock application. This bug was introduced in 67ffeb4 as per git bisect
starting from v1.7.12
; I don't know specifically what causes it.
To Reproduce
Upload the following sample to your board of choice (mine is an Arduino Uno, with a ST7735 LCD panel connected):
#include <ssd1306.h>
void setup() {
st7735_128x160_spi_init(8, 10, 9);
ssd1306_fillScreen(0x00);
ssd1306_setFixedFont(comic_sans_font24x32_123);
ssd1306_printFixed(0, 0, "111", STYLE_NORMAL);
}
void loop()
{
}
Expected behavior
I wanted to see "asd" in the screen. Instead, I get what is shown in the photo below.
Please complete the following information:
- library version: ae3339c
- LCD display type: st7735, 160x128, green tab
- OS [e.g. linux, windows]: MacOS High Sierra 10.13.6
- Platform [e.g. Atmega328p, esp32, etc.]: Arduino Uno (Atmega328p)
- IDE if using some: Arduino 1.8.9, AVR toolchain v1.6.21
Additional context
I edited the original description to use supported characters.
Thank you for reporting. I confirm, the issue exists
Can you try the following code instead?
#include <ssd1306.h>
void setup() {
st7735_128x160_spi_init(8, 10, 9);
ssd1306_fillScreen8(0x00);
ssd1306_setFixedFont(comic_sans_font24x32_123);
ssd1306_printFixed8(0, 0, "111", STYLE_NORMAL);
}
void loop()
{
}
It should work for you. Use suffix 8
for color displays.
I can confirm this works with printFixed8
. What's the issue here?
I reverted last 3 commits. So, now original example from your description should work as is.
The issue was related to the functionality, which I removed from the library. Thank you for reporting, I will think on how to do changes to the library more carefully.