Skip to content

Commit

Permalink
SCT now allows to check if wifi is connected
Browse files Browse the repository at this point in the history
  • Loading branch information
bartoszbielawski committed Apr 2, 2020
1 parent 48b85c8 commit cd18ca5
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/SerialCommand.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include <SerialCommand.h>
#include <utils.h>
#include <DataStore.h>
#include <ESP8266WiFi.h>

SerialCommandTask::SerialCommandTask() {}

Expand Down Expand Up @@ -66,6 +67,12 @@ void SerialCommandTask::run()
continue;
}

if (cmd == "connected")
{
logPrintfX(F("SCT"), F("Connected = %s"), WiFi.isConnected() ? "true": "false");
continue;
}

logPrintfX(F("SCT"), F("Unknown commmand!"));

}
Expand Down

0 comments on commit cd18ca5

Please sign in to comment.