From 67b730607146c698e573b11f23478b3a0683e9e3 Mon Sep 17 00:00:00 2001 From: Russ Hughes Date: Mon, 20 Nov 2023 17:18:15 -0800 Subject: [PATCH] Fix color error in bitmap method --- lib/st7789py.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/st7789py.py b/lib/st7789py.py index fdf10be..c81e079 100644 --- a/lib/st7789py.py +++ b/lib/st7789py.py @@ -878,8 +878,8 @@ class ST7789(): bs_bit += 1 color = bitmap.PALETTE[color_index] - buffer[i] = color & 0xff00 >> 8 - buffer[i + 1] = color_index & 0xff + buffer[i] = color >> 8 & 0xff + buffer[i + 1] = color & 0xff to_col = x + bitmap.WIDTH - 1 to_row = y + bitmap.HEIGHT - 1