Class to display Time in words on WS2812B-LED-Stripe. * Drive LEDs with PixelArray * with 11x10 LED-Matrix and 4 minute-LEDS * GERMAN LAYOUT !!!!!!
Details and usage see https://os.mbed.com/users/charly/code/WordClock/wiki/Homepage
Diff: WordClock.cpp
- Revision:
- 1:dd9657c12de6
- Parent:
- 0:0f571ea154f8
- Child:
- 2:284c13980da8
--- a/WordClock.cpp Sun Nov 05 20:30:51 2017 +0000
+++ b/WordClock.cpp Mon Nov 06 20:45:54 2017 +0000
@@ -295,6 +295,21 @@
ledstripe_[113] = hsvToRgb(hue_, saturation_, float(second)/60);
}
+void WordClock::sz()
+{
+ cls();
+ ledstripe_[4] = hsvToRgb(hue_, saturation_, value_);
+ ledstripe_[17] = hsvToRgb(hue_, saturation_, value_);
+ array_.update(ledstripe_,NUMLEDS);
+}
+
+void WordClock::wz()
+{
+ cls();
+ ledstripe_[16] = hsvToRgb(hue_, saturation_, value_);
+ ledstripe_[13] = hsvToRgb(hue_, saturation_, value_);
+ array_.update(ledstripe_,NUMLEDS);
+}
void WordClock::test_display(int option, int index)
{
@@ -310,7 +325,7 @@
break;
}
case 2 : {
- //display one LED in WHite, full brightness
+ //display one LED in White, full brightness
ledstripe_[index] = hsvToRgb(1.0, 0.0, 1.0);//white
array_.update(ledstripe_,NUMLEDS);
break;