-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/gobabygocarswithjoysticks/c…
- Loading branch information
Showing
2 changed files
with
1 addition
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
// Do not edit. Auto generated from _wifi_site.html | ||
#ifdef ARDUINO_RASPBERRY_PI_PICO_W | ||
const char indexHTML[] = " <!DOCTYPE html> <html lang='en'> <head> <title>GBG CAR</title> </head> <body> <p>Use the buttons below to turn the car's joystick on and off.</p> <button onclick='fetch(\"/activate\");' style='font-size: 100px;'>GO</button> <button onclick='fetch(\"/deactivate\");' style='font-size: 200px; float: right;'>STOP</button> <br> <div id=\"status\" style=\"font-size: 50px;\">status: </div> </body> <script> async function loop() { var errorTimeout; try { // set timeout with prototype function errorTimeout = setTimeout(() => { document.getElementById(\"status\").innerHTML = \"status: disconnected\"; }, 150); const text = await fetch('/status'); document.getElementById(\"status\").innerHTML = \"status: \" + text; clearTimeout(errorTimeout); } catch (e) { clearTimeout(errorTimeout); console.log(e); document.getElementById(\"status\").innerHTML = \"status: disconnected\"; } } setInterval(loop, 200); </script> </html>"; | ||
const char indexHTML[] = " <!DOCTYPE html> <html lang='en'> <head> <title>GBG CAR</title> </head> <body> <p>Use the buttons below to turn the car's joystick on and off.</p> <button onclick='fetch(\"/activate\");' style='font-size: 100px;'>GO</button> <button onclick='fetch(\"/deactivate\");' style='font-size: 200px; float: right;'>STOP</button> <br> <div id=\"status\" style=\"font-size: 50px;\">status: </div> </body> <script> async function loop() { var errorTimeout; try { // set timeout with prototype function errorTimeout = setTimeout(() => { document.getElementById(\"status\").innerHTML = \"status: disconnected\"; console.log(\"error timeout\"); }, 150); console.log(\"loop\"); const text = await fetch('/status'); document.getElementById(\"status\").innerHTML = \"status: \" + text; clearTimeout(errorTimeout); } catch (e) { clearTimeout(errorTimeout); console.log(\"error caught\"); console.log(e); document.getElementById(\"status\").innerHTML = \"status: disconnected\"; } } setInterval(loop, 200); </script> </html>"; | ||
#endif |
Binary file not shown.