GithubHelp home page GithubHelp logo

quadule / arduino-home-assistant Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dawidchyrzynski/arduino-home-assistant

0.0 0.0 0.0 1.11 MB

ArduinoHA allows to integrate an Arduino/ESP based device with Home Assistant using MQTT.

Home Page: https://dawidchyrzynski.github.io/arduino-home-assistant/

License: GNU Affero General Public License v3.0

JavaScript 0.08% C++ 96.03% Python 0.52% C 1.63% CSS 0.58% Makefile 0.95% HTML 0.06% Batchfile 0.15%

arduino-home-assistant's Introduction

Arduino Home Assistant integration ๐Ÿ 

ArduinoHA allows to integrate an Arduino/ESP based device with Home Assistant using MQTT. The library is designed to use as low resources (RAM/flash) as possible. Initially, it was optimized to work on Arduino Uno with Ethernet Shield, but I successfully use it on ESP8266/ESP8255 boards in my projects.

๐Ÿ“˜ Documentation

Features

  • Two-way communication (state reporting and command execution)
  • MQTT discovery (device is added to the Home Assistant panel automatically)
  • MQTT Last Will and Testament
  • Support for custom MQTT messages (publishing and subscribing)
  • Auto reconnect with MQTT broker
  • Reporting availability (online/offline states) of a device
  • Doxygen documentation for all classes
  • Covered by unit tests (AUnit + EpoxyDuino + AUniter)

Supported HA types

Home Assistant type Supported
Binary sensor โœ…
Button โœ…
Camera โœ…
Cover โœ…
Device tracker โœ…
Device trigger โœ…
Fan โœ…
Humidifier โŒ
HVAC โœ…
Light โœ…
Lock โœ…
Number โœ…
Scene โœ…
Select โœ…
Sensor โœ…
Switch โœ…
Tag scanner โœ…
Vacuum โŒ

Examples

Example Description
Binary sensor Using the binary sensor as a door contact sensor.
Button Adding simple buttons to the Home Assistant panel.
Camera Publishing the preview from the ESP32-CAM module.
Cover Controlling a window cover (open / close / stop).
Device trigger Implementation of a simple wall switch that reports press and hold states.
Fan Controlling a simple fan (state + speed).
HVAC HVAC controller with multiple modes, power control and target temperature.
Lock A simple door lock that's controlled by the Home Assistant.
Light A simple light that allows changing brightness, color temperature and RGB color.
Number Adding an interactive numeric slider in the Home Assistant panel.
Scene Adding a custom scene in the Home Assistant panel.
Select A dropdown selector that's displayed in the Home Assistant panel.
Sensor A simple sensor that reports a state in a string representation (open / opening / close).
Analog sensor Reporting the analog pin's voltage to the Home Assistant.
Integer sensor Reporting the device's uptime to the Home Assistant.
Switch The LED that's controlled by the Home Assistant.
Multi-switch Multiple switches controlled by the Home Assistant.
Tag scanner Scanning RFID tags using the MFRC522 module.
Availability Reporting entities' availability (online / offline) to the Home Assistant.
Advanced availability Advanced availability reporting with MQTT LWT (Last Will and Testament).
MQTT advanced Subscribing to custom topics and publishing custom messages.
MQTT with credentials Establishing connection with a MQTT broker using the credentials.
NodeMCU (ESP8266) Basic example for ESP8266 devices.
Arduino Nano 33 IoT Basic example for Arduino Nano 33 IoT (SAMD family).
mDNS discovery Make your ESP8266 discoverable via the mDNS.

Compatible hardware

The library uses the Arduino Ethernet Client API for interacting with the network hardware. It should work fine as long as the Client class is available.

Here is the list of devices on which the library was tested:

  • Arduino Uno
  • Arduino Mega
  • Arduino Nano
  • Arduino Pro Mini
  • Arduino Nano 33 IoT
  • NodeMCU
  • Controllino Mega (Pure)
  • Controllino Maxi (Pure)
  • ESP-01
  • ESP32-CAM
  • Sonoff Dual R2
  • Sonoff Dual R3
  • Sonoff Basic
  • Sonoff Mini
  • Tuya Wi-Fi switch module
  • Tuya Wi-Fi curtain module

Please note that it's not the complete list of supported devices. You may try to use the library on any device that uses Arduino core.

arduino-home-assistant's People

Contributors

dawidchyrzynski 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.