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

@ -400,19 +400,26 @@ bool pixelsHandler(const HomieRange& range, const String& value) {
void setup() {
Serial.begin(115200);
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");
homieNode.advertise("effect").settable(effectHandler);
homieNode.advertise("pixels").settable(pixelsHandler);
strip.begin();
strip.show(); // Initialize all pixels to 'off'
strip.setPixelColor(0, strip.Color(100,0,0));
strip.show();
delay(21240); //wait, boot bug testfix
Homie.setup();
led_fill(strip.Color(0, 0, 0));
Homie.setup();
}