GithubHelp home page GithubHelp logo

homebridge-ws2801-led-strip's Introduction

Homebridge WS2801 LED Strip Plugin

This plug-in enables you to control your WS2801 LED strip with a Raspberry Pi.

Connecting and setting up

Connect the GPIO pins from your Raspberry Pi as outlined in this table.

Raspberry Pi GPIO LED Strip Connection
Any GND Port GND
SCLK CI
MOSI DI

This will means that you won't be able to use your second SPI interface anymore, because the LED strip does not make use of the CE0 port.

Also you are going to need a power supply that provides enough current for your LED strip. In addition you should connect the GND port of your power supply with the GND port of the Raspberry Pi in someway. Most of the time this is already done with the wiring soldered onto the strip.

You can also check out the setup presented on this page. This homebridge plug-in utilizes this module.

Installation

This project is currently not submitted to npmjs so you will need to manually download this plug-in put it somewhere on your Raspberry Pi, download the dependencies and alter the command you run for homebridge to find this plug-in. How this is done can be seen on this page.

Config.json file

	{
        "accessory" : "ws2801-led-strip",
        "name" : "Floor LED",
        "led_count" : 70,
        "serial" : "XXXXXXXXXX",
        "shortPressRGB" : [230, 111, 0],
        "buttonID" : 20,
        "rewrite" : 10
    }
Key Description
accessory Required. Has to be "ws2801-led-strip"
name Required. The name of this accessory. This will appear in your homekit app
led_count Required. The number of LEDs you want to control with this plug-in. In this case 70
serial Optional. You can choose to define a serial number for this accessory
shortPressRGB Optional. You can define an RGB color that can be enable by pressing an button.
buttonID Optional. The port number where the button is connected. View previous row.
rewrite Optional. The amount of seconds after which the current status is rewritten to the strip

The way this button works is as followed. Pressing it once, will enable the color set in 'shortPressRGB'. If you press it longer but less than 1250 ms it will increase the brightness by 25 on a scale from 0 to 100. Pressing longer than 1250 ms will disable the light strip.

Issues

My LED strip turns on some LEDs (in general in the beginning of the strip) at random. This tends to happen, when I turn on any other electrical devices, which use a lot of power. I don't know why or how. This is the reason for the rewrite option, to disable this behavior as best as possible. I have mine set to 10s.

Also I have not tested this plugin in any shape or form. It works great for me but I did not test any other systems or anything. Feel free to use it and make suggestions in case of bugs.

homebridge-ws2801-led-strip's People

Contributors

lucavb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

smileyn64

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.