From 02f19df0cfa6ff6f581accf4bd17f4c75403f6b7 Mon Sep 17 00:00:00 2001 From: penfold42 Date: Wed, 4 Jul 2018 12:25:47 +1000 Subject: [PATCH] moved ssd1306 logic to options.cpp --- src/main.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/main.cpp b/src/main.cpp index dcb4e23..cd9d991 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -358,12 +358,7 @@ void InitialiseLCD() int i2cLcdOnContrast = options.I2CLcdOnContrast(); int i2cLcdDimContrast = options.I2CLcdDimContrast(); int i2cLcdDimTime = options.I2CLcdDimTime(); - - int i2cLcdModel = 0; - if (strcasecmp(options.GetLCDName(), "ssd1306_128x64") == 0) - i2cLcdModel = 1306; - else if (strcasecmp(options.GetLCDName(), "sh1106_128x64") == 0) - i2cLcdModel = 1106; + int i2cLcdModel = options.I2CLcdModel(); if (i2cLcdModel) {