Skip to content

An Arduino sketch using Homie for MQTT, and WiFi connection. Supporting transition, and working with HomeKit, and Home Assistant

Notifications You must be signed in to change notification settings

codyjamestechnical/Homie-White-LED-Controller-Sketch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

White LED Controller Sketch Using Homie

Required Libraries

Homie For ESP8266

ArduinJSON Library

What is this for

It is for use with White Only LEDs, allowing you to send standard MQTT, or MQTT JSON commands. It works with Home Assistant natively, and will work with HomeKit using MQTTTHING for HomeBridge. It supports transition( in seconds) when sending commands in JSON

How To Use

  • Set LED pins, and preferences in "config.h"
  • Upload the sketch to the board
  • Open the Homie Config site in your browser
  • Boot up, look for (and connect) to a WiFi network that looks something like lh-#########
  • It will take a few minutes for the config site to see the device, but when it does, enter your WiFi/MQTT settings
  • Now the device is on the network, all that's left is to setup HomeBridge, and Home Assistant

Commands

To send a state to any topic just add "/set" to the end. So, to get JSON state "/light/JSON", and to set that topic "/light/JSON/set"

JSON:

Topic: **/light/JSON

{
"state": "ON",
"brightness": 255,
"transition": 5
}

MQTT Topics:

State: **/light/on ( true/false )

Brightness: **/light/brightness ( 0-255 )

Brightness Percent: **/light/brightnesspct ( 0-100 )

About

An Arduino sketch using Homie for MQTT, and WiFi connection. Supporting transition, and working with HomeKit, and Home Assistant

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published