Skip to content

Commit

Permalink
Alternate approach for websocket delay on test modes
Browse files Browse the repository at this point in the history
  • Loading branch information
penfold42 committed Nov 12, 2017
1 parent 2f9c480 commit e4bb8bc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions html/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,8 @@ function wsConnect() {
case 'X6':
showReboot();
break;
case 'OK':
break;
default:
console.log('Unknown Command: ' + event.data);
break;
Expand Down
3 changes: 3 additions & 0 deletions wshandler.h
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,7 @@ void procT(uint8_t *data, AsyncWebSocketClient *client) {
testing.r = json["r"];
testing.g = json["g"];
testing.b = json["b"];
client->text("OK");
break;
}
case '2': { // Chase
Expand All @@ -229,11 +230,13 @@ void procT(uint8_t *data, AsyncWebSocketClient *client) {
testing.r = json["r"];
testing.g = json["g"];
testing.b = json["b"];
client->text("OK");
break;
}
case '3': // Rainbow
config.testmode = TestMode::RAINBOW;
testing.step = 0;
client->text("OK");
break;

case '4': { // View stream
Expand Down

0 comments on commit e4bb8bc

Please sign in to comment.