0

Several of my projects go through this time-consuming and tedious phase:

  1. design a LED pattern for a geometry of WS2812 LEDs
  2. implement it with e.g. FastLED
  3. write to Arduino and see results
  4. goto step 1

The second step, implementing different ideas in C with FastLED (or similar) takes a lot longer than I'd like it to. How is this step usually solved? Are there higher-level software solutions? Specialised idea-testing hardware?

I'd like to easily try out ideas such as "what if these four LEDs blinked magenta every second, while a gradient was cycling around the gradient over here".

3
  • Check out bhencke.com/pixelblaze . This runs on an ESP8266 and has a web interface. Here you can create your own animations using a, somewhat custom, scripting language. You can almost instantly see the results, and tweak till you get it right.
    – Gerben
    Dec 12, 2018 at 15:48
  • i setup my strip to listen to sockets, and I can push about 100 RGB levels about 15 times a second before it gets choppy. I can then use JS to preview effects i think up and code quickly. I have an example at pagedemos.com/wcz9t2xytf76/4 ; i don't know how exportable it is, but it might give you ideas...
    – dandavis
    Dec 12, 2018 at 17:23
  • 1
    Pixelblaze sounds like just what I'm looking for. Just ordered one. Thank you @gerben!
    – Anna
    Dec 14, 2018 at 12:48

2 Answers 2

3

For designing patterns for visual evaluation, it would be better to just have the arduino/controller be a pass-through from something like a full computer. There is a project called FadeCandy, which allows one to send various patterns to a WS2812 chain using a protocol called Open Pixel Control.

Some options would be to build or buy a FadeCandy board, or to implement the OPC protocol on your own arduino so that you can play around with test patterns and designs in a rapid development environment like Python or just making the raw patterns in a file and dumping that to your device over the serial port or TPC, etc.

Once you have your patterns or design the way you want it, then you can translate it to C code and FastLED, knowing you have a fixed specification you are trying to implement, rather than reflashing an arduino for every iteration.

0

I'm not sure if there are already solutions for it (high chance there are, maybe in some DMX 'simulations'), however, it shouldn't be too difficult to make your own.

Use a programming language you like which can handle graphics, use the same data structure as you would with FastLed, and let the software program (you write) show the pixels on a screen. This means you don't need any Arduino code.

If you split the filling of the pixels and the showing of it on the screen, you can copy the resulting 'filling of the pixels' code on the Arduino.

Update Another solution, if you want to experiment with the actual WS2812, is to program all patterns you want to check with FastLed, and let inputs (via UART or fancy knobs/buttons/menu) decide what patterns (and properties) are executed. The key is to program the patterns in a flexible way (so use functions with parameters for each property, and states for which pattern(s) are executed or executed next if you want to check some sequence).

2
  • Sorry for my unclear question! I'd like to test the pattern in real life. I'm playing around with diffusors and optical fibers for LED artwork, so I'd need it to happen on the actual hardware
    – Anna
    Dec 12, 2018 at 15:05
  • The step that takes too long time for a useful design cycle is implementing these relatively simple ideas ("blue bubble starting here") in C/FastLED. I'm imagining I can't be the only one looking to find a higher-level solution for prototyping this.
    – Anna
    Dec 12, 2018 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.