From d3b3020a078fff9607fd169c32210888ee6b0c5c Mon Sep 17 00:00:00 2001 From: ergosys Date: Sat, 13 Dec 2014 14:44:01 -0800 Subject: [PATCH] use gdispColor2Native to get fill color --- drivers/gdisp/SSD1306/gdisp_lld_SSD1306.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gdisp/SSD1306/gdisp_lld_SSD1306.c b/drivers/gdisp/SSD1306/gdisp_lld_SSD1306.c index 713c52bb..1885ffac 100644 --- a/drivers/gdisp/SSD1306/gdisp_lld_SSD1306.c +++ b/drivers/gdisp/SSD1306/gdisp_lld_SSD1306.c @@ -159,7 +159,7 @@ LLDSPEC bool_t gdisp_lld_init(GDisplay *g) { #if GDISP_HARDWARE_CLEARS LLDSPEC void gdisp_lld_clear(GDisplay *g) { - uint8_t fill = (g->p.color == Black) ? 0 : 0xff; + uint8_t fill = (gdispColor2Native(g->p.color) == Black) ? 0 : 0xff; int bytes = GDISP_SCREEN_WIDTH * GDISP_SCREEN_HEIGHT/8; memset(RAM(g), fill, bytes); g->flags |= GDISP_FLG_NEEDFLUSH;