Fix for obptask.cpp
This commit is contained in:
parent
9fc090a5a8
commit
574deac6f8
|
@ -49,12 +49,20 @@ void OBP60Init(GwApi *api){
|
|||
String powermode = api->getConfig()->getConfigItem(api->getConfig()->powerMode,true)->asString();
|
||||
api->getLogger()->logDebug(GwLog::DEBUG,"Power Mode is: %s", powermode.c_str());
|
||||
if(powermode == "Max Power" || powermode == "Only 5.0V"){
|
||||
#ifdef HARDWARE_V21
|
||||
setPortPin(OBP_POWER_50, true); // Power on 5.0V rail
|
||||
#endif
|
||||
#ifdef HARDWARE_LIGHT
|
||||
setPortPin(OBP_POWER_EPD, true);// Power on ePaper display
|
||||
#endif
|
||||
}
|
||||
else{
|
||||
#ifdef HARDWARE_V21
|
||||
setPortPin(OBP_POWER_50, false); // Power off 5.0V rail
|
||||
#endif
|
||||
#ifdef HARDWARE_LIGHT
|
||||
setPortPin(OBP_POWER_EPD, false);// Power off ePaper display
|
||||
#endif
|
||||
}
|
||||
|
||||
// Settings for e-paper display
|
||||
|
|
Loading…
Reference in New Issue