Giter Club home page Giter Club logo

arduinoledanimator2021's Introduction

Arduino LED Animator 2021

Devlog [2021-01-24]

I’m making this project to control the WSITEM-100149 (‘18-inch fancy 2x4 lamp’ made in 2019) and any future, similar light fixtures:

  • A strip of individually-addressed LEDs (WS2812B?), which has some kind of animation going
  • A single-color LED light strip that can be turned on or off

Could get fancier (RGBW, more animation options), but for now I just want:

  • To be able to control the lights via MQTT:
    • Solid-color light states: off, on
    • WS2812 strip states: off, solid color, animated

Thinking ‘solid color’ could just be a special case of animated, depending how it’s defined. Currently thinking parameters would just be numeric multipliers for:

  • Movement-across-strip speed
  • The speed of a set of oscillators
  • R, G, B multipliers for each oscillator to give the next value

Is it worth doing ‘anti-aliasing’? Whatever; for now I should just try to get the thing working basically.

Basing this project on PowerCube because I wrote some nice C++ classes for these Arduino projects in there, but I plan to remove most of it.

This may turn into yet another unused project cluttering up my proj/ folder. If there is no new devlog entry by 2022, it’s probably safe to delete.

I haven’t been able to find any documentation on WSITEM-100149 and attached boards. Is this thing even running PowerCube? I’m not sure! But grepping for “FastLED” hasn’t turned up anything else.

Should I use PlatformIO or Arduino?

One reason I was making the ‘PowerCube’ project was that sharing libraries between projects when using Arduino IDE seemed difficult. They have to be installed globally. Haven’t messed with PlatformIO enough to know if it’s any better. But I keep rewriting things like WiFi and MQTT connection maintenance, command parsing, etc. Would be nice to have a template project that has my usual stuff in it, and have the stuff be shared libraries.

But I am thinking too much. Just try to make the lights work.

What should the MQTT API look like?

This stuff should be pretty standard. It seems like homie keeps changing their ideas about ‘online’/’disconnected’/etc, though I could be misremembering.

read ..devicename.../status online|offline
write ..devicename.../solid1/state/set on   ; turn solid white LED strip on
write ..devicename.../solid1/state/set off  ; turn solid white LED strip off
write ..devicename.../anim1/state/set animating ; turn on the animated lights in animated mode
write ..devicename.../anim1/state/set #rrggbb ; turn on the animated lights and set them to a specific static color
write ..devicename.../anim1/state/set off   ; turn off the animated lights
...various animation controls tb

The …state/set topics might in the future be shorthand for changing more complex sets of variables, in which case there will be no single ‘state’ topics to read.

Devlog [2021-01-24T03:23]

Ha ha! By dumping that PowerCube baggage, This project is already more advanced!

Oscillator parameters are reset on reboot.

I don’t necessarily want to stick with this oscillator model, and it would be cool to be able to control things remotely, but until then, this works, I guess.

arduinoledanimator2021's People

Contributors

togos avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.