Recent

Author Topic: WS2812 LED string demo with attiny10  (Read 617 times)

ccrause

  • Hero Member
  • *****
  • Posts: 970
WS2812 LED string demo with attiny10
« on: October 25, 2024, 10:24:13 pm »
Bought an addressable RGB LED string (WS2812 compatible) and wanted to test whether an attiny10 can manage bit-banging the protocol and generate some effects. Demo code here. Attached gif shows the t10 in action driving the LED string.

Edit: updated link.
« Last Edit: October 28, 2024, 06:02:39 am by ccrause »

ackarwow

  • Jr. Member
  • **
  • Posts: 82
    • Andrzej Karwowski's Homepage
Re: WS2812 LED string demo with attiny10
« Reply #1 on: October 27, 2024, 08:52:45 pm »
Many thanks for your excellent pascal library for AVRs! However it seems, that this link is broken...

dseligo

  • Hero Member
  • *****
  • Posts: 1418
Re: WS2812 LED string demo with attiny10
« Reply #2 on: October 27, 2024, 09:45:41 pm »
Many thanks for your excellent pascal library for AVRs! However it seems, that this link is broken...

He changed it a little, here is new link: https://github.com/ccrause/fpc-avr/tree/master/src/examples/ws2812-led

To ccrause: this looks great, I am looking forward to try this code. :)

ccrause

  • Hero Member
  • *****
  • Posts: 970
Re: WS2812 LED string demo with attiny10
« Reply #3 on: October 28, 2024, 06:00:44 am »
Many thanks for your excellent pascal library for AVRs! However it seems, that this link is broken...

He changed it a little, here is new link: https://github.com/ccrause/fpc-avr/tree/master/src/examples/ws2812-led

To ccrause: this looks great, I am looking forward to try this code. :)

Thanks for posting the correct link dseligo. I targeted the attiny10 initially, then refactored the code a bit to make it more general.

It is a lot of fun playing with these LED strings.

MarkMLl

  • Hero Member
  • *****
  • Posts: 8039
Re: WS2812 LED string demo with attiny10
« Reply #4 on: November 01, 2024, 12:51:02 pm »
There's a couple of issues with those LED strings, plus one with potential users :-)

(I'm sure everybody here present is aware of that, but I'm writing more for people who arrive here via Google.)

The first string issue is that while the WS2812 is a 5V device, the WS2811 ** operates at 12V which is a substantial improvement for long runs.

The second string issue is that the WS2813/WS2815 ** has an additional bypass connection so that if an LED goes dud it only affects that one pixel, rather than killing everything else downstream.

The user issue is that a recurrent question in various foramina is "I've got 1,000 pixels hooked up to an Arduino: how do I get a 60Hz frame update?".

The bottom line is that you're best off connecting a single row of pixels to each controller chip, and having an additional chip select and RLL download protocol to control the entire display.

I think the project below is about the limit, so while it might be scalable physically it will need more controllers if it gets much bigger.

https://hackaday.com/2021/06/07/portable-digital-scoreboard-goes-anywhere/

** Numbers largely from memory.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

 

TinyPortal © 2005-2018