Skip to content

Commit

Permalink
feat: move getPixels to http request to save power
Browse files Browse the repository at this point in the history
  • Loading branch information
TheRealWaldo committed Aug 26, 2021
1 parent 99dc924 commit 072bb1f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@ void getRaw()

void sendRaw()
{
getPixels();
getRaw();
server.send(200, "application/json", output.c_str());
}

Expand Down Expand Up @@ -153,8 +155,6 @@ void loop()
{
if (WiFi.status() == WL_CONNECTED)
{
getPixels();
getRaw();
delay(100);
server.handleClient();
}
Expand Down

0 comments on commit 072bb1f

Please sign in to comment.