Index: target/dartuinoP0/include/target/display/LS013B7DH06.h |
diff --git a/target/dartuinoP0/include/target/display/LS013B7DH06.h b/target/dartuinoP0/include/target/display/LS013B7DH06.h |
index e4cd964c8de09b060b8b0ede8350f219392d8200..1adbef2f57c44997166550328e96305a5c35d6d3 100644 |
--- a/target/dartuinoP0/include/target/display/LS013B7DH06.h |
+++ b/target/dartuinoP0/include/target/display/LS013B7DH06.h |
@@ -30,16 +30,11 @@ |
#define MLCD_WIDTH ((uint16_t)128) |
#define MLCD_HEIGHT ((uint16_t)128) |
+// Ensure width corresponds to an integral number of bytes |
+STATIC_ASSERT(((MLCD_WIDTH * 3) & 0x3) == 0); |
+ |
// 3 bits per pixel (1 for each of RBG) divided by 8 bits per byte. |
#define MLCD_BYTES_LINE ((MLCD_WIDTH * 3) / 8) |
+#define MLCD_FORMAT (DISPLAY_FORMAT_RGB_111) |
-#if 0 |
-// For gbskia |
-#define FB_FORMAT (DISPLAY_FORMAT_RGB_x111) |
-#define FB_STRIDE ((MLCD_WIDTH + 1) >> 1) |
-#else |
-#define FB_FORMAT (DISPLAY_FORMAT_RGB_332) |
-#define FB_STRIDE (MLCD_WIDTH) |
-#endif |
- |
-uint8_t lcd_get_line(uint8_t *framebuffer, uint8_t idx, uint8_t *result); |
+uint8_t lcd_get_line(struct display_image *image, uint8_t idx, uint8_t *result); |