mirror of
https://gitlab.com/zwirbel/illucat.git
synced 2025-12-16 10:04:30 +01:00
externalize pixel stuff, add pixel instance to plugin, remove old code
This commit is contained in:
@@ -66,6 +66,7 @@ class NeoPattern : public Adafruit_NeoPixel
|
||||
frameBuffer = (uint8_t *)malloc(768);
|
||||
OnComplete = callback;
|
||||
TotalSteps = numPixels();
|
||||
begin();
|
||||
}
|
||||
|
||||
NeoPattern(uint16_t pixels, uint8_t pin, uint8_t type)
|
||||
@@ -73,6 +74,7 @@ class NeoPattern : public Adafruit_NeoPixel
|
||||
{
|
||||
frameBuffer = (uint8_t *)malloc(768);
|
||||
TotalSteps = numPixels();
|
||||
begin();
|
||||
}
|
||||
|
||||
void handleStream(uint8_t *data, size_t len)
|
||||
@@ -386,6 +388,9 @@ class NeoPattern : public Adafruit_NeoPixel
|
||||
return Color(WheelPos * 3, 255 - WheelPos * 3, 0);
|
||||
}
|
||||
}
|
||||
/**
|
||||
* Effects from https://www.tweaking4all.com/hardware/arduino/adruino-led-strip-effects/
|
||||
*/
|
||||
void Fire(int Cooling, int Sparking)
|
||||
{
|
||||
byte heat[numPixels()];
|
||||
|
||||
Reference in New Issue
Block a user