Skip to content

Commit

Permalink
Added RD HTTP api call for realtime udp
Browse files Browse the repository at this point in the history
  • Loading branch information
Aircoookie committed Mar 9, 2019
1 parent 0166dfe commit b9c27ed
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion wled00/wled00.ino
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@


//version code in format yymmddb (b = daily build)
#define VERSION 1903072
#define VERSION 1903091
char versionString[] = "0.8.4-dev";


Expand Down
15 changes: 7 additions & 8 deletions wled00/wled03_set.ino
Original file line number Diff line number Diff line change
Expand Up @@ -527,6 +527,10 @@ bool handleSet(AsyncWebServerRequest *request, String req)
//toggle receive UDP direct notifications
pos = req.indexOf("RN=");
if (pos > 0) receiveNotifications = (req.charAt(pos+3) != '0');

//receive live data via UDP/Hyperion
pos = req.indexOf("RD=");
if (pos > 0) receiveDirect = (req.charAt(pos+3) != '0');

//toggle nightlight mode
bool aNlDef = false;
Expand Down Expand Up @@ -665,14 +669,9 @@ bool handleSet(AsyncWebServerRequest *request, String req)
overlayRefreshedTime = 0;
}
#endif
pos = req.indexOf("NM="); //mode, 1 countdown
if (pos > 0) {
countdownMode = true;
if (req.indexOf("NM=0") > 0)
{
countdownMode = false;
}
}
//mode, 1 countdown
pos = req.indexOf("NM=");
if (pos > 0) countdownMode = (req.charAt(pos+3) != '0');

pos = req.indexOf("U0="); //user var 0
if (pos > 0) {
Expand Down

0 comments on commit b9c27ed

Please sign in to comment.