So, I had a crazy idea.

So, I had a crazy idea. I’ve been playing with the new ATTiny85 support (using a bare atttiny85 instead of a trinket this time (http://hlt.media.mit.edu/?p=1695)).

I love the little chips, but I’m always pushing the memory limits. I’m also always pushing the power limits and so I tend to run my ws2812’s at low brightness (32 or so). That is, I want lots of dim lights controlled my a small computer (yeah, wearables).

So here’s my idea. How about a mode of FastSPI where I can give you a smaller array of lights to illuminate and you write out black (or a ‘background color’ for all of the pixels in the strip that aren’t in the smaller array).

Then I could use a much smaller array (just the side of the ‘sprite’ that’s moving around).

So it would go something like this

#define NUM_LEDS 120
#define SPRITE_LENGTH 32

CRGB leds[SPRITE_LENGTH];

void setup() {
LEDS.addLeds<WS2811, 3, GRB>(leds, NUM_LEDS);
LEDS.setBackground(CRGB::Black);
}

// move the sprite down the line of lights
void loop() {
static byte offset = 0;
while (offset < NUM_LEDS - SPRITE_LENGTH) {
strip.show(offset++);
delay(20);
}
offset = 0;
}
http://hlt.media.mit.edu/?p=1695

“Dynamic pixel windows”, let’s call it. It’s probably possible (cycle-wise), and there are other interesting uses for it.

We have a pretty deep queue of new features we want to implement, but consider this officially added to the list. Given the other things we want to get to first (eg Due support, [REDACTED], etc), I wouldn’t bet on this one anytime soon, but we’ll keep kicking it around as an idea.

The related thing that I’ve been thinking about recently is the ability to repeat a pattern multiple times on one strip, eg pixels 0-99, pixels 100-199, and pixels 200-299 all being driving from a single 100-element CRBG array. You can do this already now if you have two separate strips on two different pins: just addLEDs twice using the same buffer. But I’m musing on the possibilities of arbitrary mappings from pixel ranges to buffer ranges-- which would include the possibility you mentioned.

Again: not coming any time soon or maybe even at all, but it’s interesting to think about, just for brainstorming.

the repeat thing is something i’ve also considered. if that’s easier (sooner) i could definitely make it work. my patterns are rarely regular (mostly being clothes and such), but I could definitely work around that.

For now I’ll just use more advanced chips for the more advanced stuff. It would be awesome if there was an 8-pin attiny with way more ram… probably not in the cards since everyone is going smd these days. i still need to bite that bullet.

so many bullets to byte so little time…

Anyway, love the library as is. keep up the good work!

I’ve been using a pic12f1822 to drive the ws2812. You have a fair amount of flash memory and can use that as a lookup table for your color pattern. I’ve done that to reduce my color sequences to 1 byte per LED. It requires that you pick up to 256 colors for the lookup table.