Logging: change string to c-string

This commit is contained in:
norbert-walter 2024-09-18 15:21:57 +02:00
parent 1b7c0f6f11
commit ed2439febc
1 changed files with 3 additions and 3 deletions

View File

@ -49,7 +49,7 @@ void OBP60Init(GwApi *api){
// Settings for e-paper display // Settings for e-paper display
String fastrefresh = api->getConfig()->getConfigItem(api->getConfig()->fastRefresh,true)->asString(); String fastrefresh = api->getConfig()->getConfigItem(api->getConfig()->fastRefresh,true)->asString();
api->getLogger()->logDebug(GwLog::DEBUG,"Fast Refresh Mode is: %s", fastrefresh); api->getLogger()->logDebug(GwLog::DEBUG,"Fast Refresh Mode is: %s", fastrefresh.c_str());
#ifdef DISPLAY_GDEY042T81 #ifdef DISPLAY_GDEY042T81
if(fastrefresh == "true"){ if(fastrefresh == "true"){
static const bool useFastFullUpdate = true; // Enable fast full display update only for GDEY042T81 static const bool useFastFullUpdate = true; // Enable fast full display update only for GDEY042T81
@ -64,7 +64,7 @@ void OBP60Init(GwApi *api){
// Settings for backlight // Settings for backlight
String backlightMode = api->getConfig()->getConfigItem(api->getConfig()->backlight,true)->asString(); String backlightMode = api->getConfig()->getConfigItem(api->getConfig()->backlight,true)->asString();
api->getLogger()->logDebug(GwLog::DEBUG,"Backlight Mode is: %s", backlightMode); api->getLogger()->logDebug(GwLog::DEBUG,"Backlight Mode is: %s", backlightMode.c_str());
uint brightness = uint(api->getConfig()->getConfigItem(api->getConfig()->blBrightness,true)->asInt()); uint brightness = uint(api->getConfig()->getConfigItem(api->getConfig()->blBrightness,true)->asInt());
String backlightColor = api->getConfig()->getConfigItem(api->getConfig()->blColor,true)->asString(); String backlightColor = api->getConfig()->getConfigItem(api->getConfig()->blColor,true)->asString();
if(String(backlightMode) == "On"){ if(String(backlightMode) == "On"){
@ -79,7 +79,7 @@ void OBP60Init(GwApi *api){
// Settings flash LED mode // Settings flash LED mode
String ledMode = api->getConfig()->getConfigItem(api->getConfig()->flashLED,true)->asString(); String ledMode = api->getConfig()->getConfigItem(api->getConfig()->flashLED,true)->asString();
api->getLogger()->logDebug(GwLog::DEBUG,"LED Mode is: %s", ledMode); api->getLogger()->logDebug(GwLog::DEBUG,"LED Mode is: %s", ledMode.c_str());
if(String(ledMode) == "Off"){ if(String(ledMode) == "Off"){
setBlinkingLED(false); setBlinkingLED(false);
} }