From dc30e2ac6322f72d693744c8f1eb37ce05d40f69 Mon Sep 17 00:00:00 2001 From: prenticedavid Date: Sat, 21 Apr 2018 16:30:19 +0100 Subject: [PATCH] NL must be correct for vertical scroll --- MCUFRIEND_kbv.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MCUFRIEND_kbv.cpp b/MCUFRIEND_kbv.cpp index bd9d827..5d65909 100644 --- a/MCUFRIEND_kbv.cpp +++ b/MCUFRIEND_kbv.cpp @@ -427,7 +427,8 @@ void MCUFRIEND_kbv::setRotation(uint8_t r) _MC = 0x20, _MP = 0x21, _MW = 0x22; GS = (val & 0x80) ? (1 << 9) : 0; SS_v = (val & 0x40) ? (1 << 8) : 0; - WriteCmdData(0x01, GS | SS_v | 0x0028); // set Driver Output Control + // S6D0139 requires NL = 0x27, S6D0154 NL = 0x28 + WriteCmdData(0x01, GS | SS_v | ((_lcd_ID == 0x0139) ? 0x27 : 0x28)); goto common_ORG; #endif case 0x5420: