changed setup procedure slightly

This commit is contained in:
interfisch 2017-01-04 22:06:29 +01:00
parent c417625666
commit 333c72db68
1 changed files with 12 additions and 5 deletions

View File

@ -401,19 +401,26 @@ void setup() {
Serial.begin(115200); Serial.begin(115200);
Serial << endl << endl; Serial << endl << endl;
strip.begin();
strip.show(); // Initialize all pixels to 'off'
led_fill(strip.Color(100, 0, 0));
Homie_setFirmware("pixelprojektor", "1.0.0"); Homie_setFirmware("pixelprojektor", "1.0.0");
homieNode.advertise("effect").settable(effectHandler); homieNode.advertise("effect").settable(effectHandler);
homieNode.advertise("pixels").settable(pixelsHandler); homieNode.advertise("pixels").settable(pixelsHandler);
strip.begin(); strip.setPixelColor(0, strip.Color(100,0,0));
strip.show(); // Initialize all pixels to 'off' strip.show();
delay(21240); //wait, boot bug testfix
Homie.setup();
led_fill(strip.Color(0, 0, 0)); led_fill(strip.Color(0, 0, 0));
Homie.setup();
} }