Git Product home page Git Product logo

fade_leds's Introduction

README: fade_leds

fade_leds is a quick-and-dirty command line utility that controls a strand of WS2812 LEDs hanging off a Raspberry Pi. These LEDs are often sold by Adafruit under the brand name "Neopixels".

To use the utility:

 `fade_leds color-1 color-2 [color...]`

...where each color is a hex string (with or without the leading 0x). The program will immediately display color-1 on all LEDs in the strand, and then will fade into color-2 over a one-second interval, and so on with each color specified, taking one second to transition between each color pair. At the end of execution, the LEDs will be left showing the last color listed.

At the moment everything is hardcoded for my particular setup, using a strand of 5 LEDs and GPIO pin 18 (in "BCM" numbering; that corresponds to pin 12 in "Board" numbering). To change these assumptions, edit the #defines in fade_leds.c. Obviously, in the long term all of these should be made into command line parameters.

The fade_leds utility requires the rpi_ws281x library, available at GitHub. (Only the C library libws2811.a is required from that project -- not the Python stuff.)

Because the LEDs are driven using DMA, this utility must be installed setuid root.

To build:

   make
   sudo make install

fade_leds's People

Contributors

howdypierce avatar

Stargazers

Nimish Bhide avatar

Watchers

James Cloos 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.