Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfix: add 4s delay before shutting down client, after wifi credential exchange #54

Merged
merged 1 commit into from
Oct 9, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sockets_client.ino
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ void webSocketEvent(WStype_t type, uint8_t * payload, size_t length) {
case WStype_DISCONNECTED:
Serial.println("[WSc] Disconnected!\n");
//Hot fix for when client doesn't catch RESTART command
softReset(0);
softReset(4000);
break;
case WStype_CONNECTED:
Serial.println("Connected!");
Expand All @@ -25,7 +25,7 @@ void webSocketEvent(WStype_t type, uint8_t * payload, size_t length) {
#endif
String output = (char *)payload;
if (output == "RESTART") {
softReset(0);
softReset(4000);
Serial.println("i'm going to reset");
} else {
decodeData((char *)payload);
Expand Down