diff --git a/src/app/app.ino b/src/app/app.ino index 8f1db3b..004b500 100644 --- a/src/app/app.ino +++ b/src/app/app.ino @@ -42,7 +42,8 @@ void setup() if(cfgDictionary != NULL) { - Serial.print("AP PASSWORD : ");if((*cfgDictionary)("PASSWORD") != NULL)Serial.println((*cfgDictionary)("PASSWORD")->stringValue()); + Serial.printf("AP PASSWORD : %s\n", + (*cfgDictionary)("PASSWORD") ? (*cfgDictionary)("PASSWORD")->stringValue() : ""); } #if 0 @@ -92,6 +93,7 @@ void setup() sab.getWebServer().addApiRoutine("/sab/io/set/level", &(ioSetLevelApi), &sab, WEBServer::GET); sab.getWebServer().addApiRoutine("/sab/io/get/mode", &(ioGetModeApi), &sab, WEBServer::GET); sab.getWebServer().addApiRoutine("/sab/io/set/mode", &(ioSetModeApi), &sab, WEBServer::GET); + sab.getWebServer().addApiRoutine("/sab/ota/update", &(otaUpdateApi), NULL, WEBServer::POST); sab.getIoManager().setISROnIOChange(&(ioISR), GPIO_3_RX);