Giter VIP home page Giter VIP logo

homebridge-simple-wled-gcmms's Introduction

Homebridge Simple WLED

Homebridge Plugin for WLED Strip (WLED-Project by Aircoookie)

❓HELP

For faster support and Informations join my discord https://discord.gg/qpbUtZCB2H

⚙️ Installation / NPM Package

For downloading and installing the Plugin NPM is used in Homebridge: Link to NPM Package

🔨 Adding the Accessory to the config.json

To make the accessory visible in your HomeKIT App you have to add the Platform-Accessory to the config.json to the platforms section:

    "platforms": [
        {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus"],
                    "log": true
                },
                {
                    "name": "LED-Kasten",
                    "host": ["10.0.0.53", "10.0.0.54"],
                    "effects": ["Rainbow Runner", "Circus"],
                }
            ]
        }
    ]

After editing the config, restart your HomeBridge Server and add the accessory manually from the Home App. If you encounter some issues when adding the accessory to the homekit app, open an issue in GitHub...

💡 Configure own Effect-Switch

You can't enable the Effect-Switch and Preset-Switch at the same time!

To use your own effects you have an option "effects" you can add to your config.json and add as value a comma-seperated list of supported effects of your choice. All effects are found under Effects-List - WLED (Just use Names from the Effects and not from the palettes!!)

sample additional option:

    "platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                    "log": false
                }
            ]
        }
    ]

If you want to turn off the WLED when turning off the WLED-Effect-Switch then you can add the option "turnOffWledWithEffect", (default: false)

    "platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                    "turnOffWledWithEffect": true
                }
            ]
        }
    ]

If you want to disable the Effect-Switch to just use the normal "LightBulb" function. You can just remove the "effects" option in the config.json.

🛠 Configure Effect speed

To configure the speed of your effects, you can define a standard Speed in your config.json:

"defaultEffectSpeed": <NUMBER FROM 1-255> (Standard is 15) (optional)

"platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                    "log": false,
                    "defaultEffectSpeed": 20
                }
            ]
        }
    ]

or you can add a Effect Speed Control Element (Lightbulb accessory which controls the Effect speed)

"showEffectControl": (Standard is false) (optional)

"platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                    "log": false,
                    "showEffectControl": true
                }
            ]
        }
    ]

💡 Configure own Preset-Switch

You can't enable the Effect-Switch and Preset-Switch at the same time!

To use your own presets you have an option "presets" you can add to your config.json and add as value a comma-seperated list of supported presets of your choice. You can name them what every you choose them to be, but the order of them has to be the same as in wled. (Ex. Preset 1 is assigned to the first index of the list.)

sample additional option:

    "platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "presets": ["Christmas", "Halloween", "Morning", "Night"],
                    "log": false
                }
            ]
        }
    ]

If you want to disable the Preset-Switch to just use the normal "LightBulb" function. You can just remove the "presets" option in the config.json.

💡💡💡 Adding multiple WLED-hosts to a single accessory

If you want to control multiple WLED-hosts with a single accessory, you have to set the "host" option to a list/array as below: Note: The first WLED-host will act like a main-WLED, so for example, you change the color of the first WLED (10.0.0.52) via the WEB-Panel of the WLED it also changes for the following WLEDS (10.0.0.53, 10.0.0.54,...).

    "platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": ["10.0.0.52", "10.0.0.53", "10.0.0.54"],
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                }
            ]
        }
    ]

🌦 Adding a switch for Ambilight/Moodlight or Adalight/Moodlight

If you want to add a switch, to switch between Ambilight and Moodlight you have to add the "ambilightSwitch" option. This works also with multiple IP-Adresses and effects like described above.

If not specified, it's default off/false

    "platforms": [
                {
            "platform": "WLED",
            "wleds": [
                {
                    "name": "LED-Tisch",
                    "host": "10.0.0.52",
                    "effects": ["Rainbow Runner", "Circus", "Merry Christmas", "Fireworks"],
                    "log": false,
                    "ambilightSwitch": true
                }
            ]
        }
    ]

Contributing

If you have any idea, feel free to fork it and submit your changes back to me.

Donation

You can also support me developing this plugin by buying me a coffee and giving me motivation to keep this plugin up to date and continue developing.

Thanks to everyone who is donating to me.

Buy me a coffee to stay motivated for programming :D
Buy Me A Coffee

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.