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: PixelArray WordClock_de ds3231 mbed
Fork of mbed_ws2812b by
Diff: main.cpp
- Revision:
- 3:ebe0c4fa97b8
- Parent:
- 2:d39f37d64441
- Child:
- 4:ed0ac1dd6ae4
--- a/main.cpp Sun Nov 05 10:27:14 2017 +0000
+++ b/main.cpp Sun Nov 05 18:25:59 2017 +0000
@@ -40,21 +40,29 @@
timer.start();
while(1) {
+ // time fast forward
+ for (int h=0; h<=23; h++) {
+ for (int m=0; m<=59; m++) {
+ clock.display_time(h,m);
+ wait_ms(500);
+ }
+ }
+
// all words
- for (int i=1; i<=NUMWORDS;i++) {
+ for (int i=1; i<=NUMWORDS; i++) {
clock.test_display(3,i);
- wait_ms(800);
- }
+ wait_ms(800);
+ }
//all leds on with rainbow colors
while ( int(timer.read()/10.0) %2 == 0) {
clock.test_display(1);
wait_ms(100);
}
// every led on for 250ms
- for (int i=0; i<NUMLEDS;i++) {
- clock.test_display(2,i);
- wait_ms(250);
- }
+ for (int i=0; i<NUMLEDS; i++) {
+ clock.test_display(2,i);
+ wait_ms(250);
+ }
timer.reset();
}
}
