Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed ESP8266_WebServer
Revision 28:ba5c68a04f56, committed 2015-01-08
- Comitter:
- sschocke
- Date:
- Thu Jan 08 18:25:16 2015 +0000
- Parent:
- 27:88093aa94e24
- Commit message:
- Disco Mode
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 88093aa94e24 -r ba5c68a04f56 main.cpp
--- a/main.cpp Thu Jan 08 11:03:11 2015 +0000
+++ b/main.cpp Thu Jan 08 18:25:16 2015 +0000
@@ -56,9 +56,9 @@
{
for ( int c = 0; c < LED_COUNT; c++ )
{
- colors[c].red = rand()%255;
- colors[c].green = rand()%255;
- colors[c].blue = rand()%255;
+ colors[c].red = rand()%100;
+ colors[c].green = rand()%100;
+ colors[c].blue = rand()%100;
}
ledStrip.write(colors, LED_COUNT);
@@ -157,7 +157,10 @@
httpReply += "<tr><td align='center'>";
httpReply += "<img style='margin-right:2px' src='colormap.gif' usemap='#colormap' />";
httpReply += "<map id='colormap' name='colormap'>";
- httpReply += "</map></td></tr><tr><td><span onClick=\"changeColor('#000000')\">Turn Off</span></td></tr></table>";
+ httpReply += "</map></td></tr>";
+ httpReply += "<tr><td><span onClick=\"window.location='/disco'\">Disco Mode</span></td></tr>";
+ httpReply += "<tr><td><span onClick=\"changeColor('#000000')\">Turn Off</span></td></tr>";
+ httpReply += "</table>";
httpReply += htmlTail;
server.SendReply(request->LinkID, httpReply, mimeHTML);
} else if( request->URI == "/config" ) {
