Code Monkey home page Code Monkey logo

zylinderino's Introduction

RGB-Strip Controller

PCB Requirements:

  • 4x 12V PWM Transistors
  • 1/2 ARGB Pins + 5V supply
  • ESP8266 SMD traces
  • 12V-5V Buck converter

Sketch is neither correct nor conventional, it's just to show the general layout and routing beforehand. The left half could be supplied with its own 5V supply, and then the right half with the buck converter, transistors and all 12V shenanigans could be broken off for a very tiny ARGB controller

photo_2022-06-12_12-32-20

Kicad ESP footprints used: https://github.com/jdunmire/kicad-ESP8266

zylinderino's People

Contributors

victoriafoxgirl avatar nandbert avatar

Watchers

 avatar

zylinderino's Issues

Separate g_aLeds into two to avoid recursion

When calling g_aLeds[i].nscale8(brightness) every tick, previous colors get asymptotically erased.
Split into two arrays:
One which the work is done in, and the render() methods are called, and
One which in the end the first array is copied into, and then dimmed.

This enables behaviour like LEDs leaving traces, and effects overwriting others.

color picker module for html

So far, whenever you choose either a single color or multiple, the code is the same.
Handle it in the global webhandler, and make a concatenatable HTML block.

Also: instead of having five radio buttons and one color picker, just use five color pickers.

Bonus points: Remember the point in the html string where "value="#ff00ff" " is, and dynamically snprintf/memcopy the current color value, so it represents the status quo

Implicit function display?

Check out Marching Squares algorithm, although at such a low resolution maybe find something else?

Metaballs you know

Replace coords() with setPixel() and getPixel()

directly manipulating the LED array with pointers may be a bad idea, even though we do have our dummy led for parameter faults.
When using a setPixel() and getPixel() function, this may be more general so future compability is assured.

on the Other hand, keep the choords() function for advanced stuff like calling CRGB::methods, and just have a getPixel/setPixel function that acts as a wrapper around choords()

Split in multiple files

Slowly reaching the 1000 lines of code, maybe break it up into multiple files for readability

Bubbles mode

Have bubbles (or other sprites, e.g. hearts) rise from quasi-random locations

Multi-Mode

Have two modes overlapping, for example Zepelli mode + circle, or Rainbow + Text

TrueType Font

Instead of having every Character being 5x7, have them have individual widths.
Individual Widths may be saved in a separate global array (or maybe make a class out of letters?)
Managing the g_aFont array:

  1. Keep it the same and have the letters left justified and fill with 0's, to make indexing easy or
  2. have a cumulative array of widths, to lookup the array indices, similar to the g_aLeds array.
  3. Make it a class.
    -> maybe have a method render(x) that renders the character into the array at the given coordinate
    and automatically increases x (via return value or pointer).

This makes it difficult to have differently colored letters however.

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.