mirror of
https://github.com/meshcore-dev/MeshCore.git
synced 2026-04-20 22:13:47 +00:00
fixed flickering of sh1107 display with cheap hack
This commit is contained in:
parent
e59dc47c0b
commit
62a62eb5c3
1 changed files with 3 additions and 1 deletions
|
|
@ -25,6 +25,8 @@ bool SH1107Display::begin()
|
|||
void SH1107Display::turnOn()
|
||||
{
|
||||
display.oled_command(SH110X_DISPLAYON);
|
||||
uint8_t cmd[] = {0xD5, 0xF0};
|
||||
display.oled_commandList(cmd, 2);
|
||||
_isOn = true;
|
||||
}
|
||||
|
||||
|
|
@ -43,7 +45,7 @@ void SH1107Display::clear()
|
|||
void SH1107Display::startFrame(Color bkg)
|
||||
{
|
||||
display.clearDisplay(); // TODO: apply 'bkg'
|
||||
display.setContrast(300); // 0-255. default setting was causing some flickering.
|
||||
display.setContrast(120); // 0-127. default setting was causing some flickering.
|
||||
// display.SH110X_SETPRECHARGE(255);
|
||||
_color = SH110X_WHITE;
|
||||
display.setTextColor(_color);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue