Library for interfacing to Nokia 5110 LCD display (as found on the SparkFun website).
Diff: Bitmap.cpp
- Revision:
- 42:596c207519de
- Parent:
- 41:6c046786be6c
- Child:
- 50:c293d29e035a
diff -r 6c046786be6c -r 596c207519de Bitmap.cpp --- a/Bitmap.cpp Wed Mar 08 16:13:08 2017 +0000 +++ b/Bitmap.cpp Tue Mar 21 10:43:19 2017 +0000 @@ -87,10 +87,10 @@ // Column index on the screen for rendering this pixel int screen_col = x0 + bitmap_col; + // Find the required value of the pixel at the given location within + // the bitmap data and then write it to the LCD screen int pixel = get_pixel(bitmap_row, bitmap_col); - - if(pixel) lcd.setPixel(screen_col, screen_row); - else lcd.clearPixel(screen_col, screen_row); + lcd.setPixel(screen_col, screen_row, pixel); } } } \ No newline at end of file