strip.clear() statt manueller Routine

This commit is contained in:
starcalc 2018-01-30 22:38:02 +01:00
parent 7eedc8a0a0
commit dbd05e4408
1 changed files with 6 additions and 5 deletions

View File

@ -362,10 +362,11 @@ void loop() {
// Zeige aktuelle Quelle auf dem Strip an
strip.None();
for (int j=0;j<NUMPIXELS;j++)
{
strip.setPixelColor(j, strip.Color(0, 0, 0));
}
strip.clear();
// for (int j=0;j<NUMPIXELS;j++)
// {
// strip.setPixelColor(j, strip.Color(0, 0, 0));
// }
strip.show();
strip.colorBox(inputbytes[1]-128, strip.Color(255, 255, 255));
// strip.setPixelColor((inputbytes[1]-128)*3, strip.Color(255, 0, 0));
@ -386,7 +387,7 @@ void loop() {
Serial.print("<");
currentnumber++;
}
if (millis() > lastMillis + 1000)
if (millis() > lastMillis + 1000) // Timeout
{
currentnumber = 0;
}