arthurlutz / microhomie

MicroPython implementation of the Homie MQTT convention for IoT.

Home Page:https://microhomie.readthedocs.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Microhomie

Documentation Status

Microhomie is a MicroPython framework for Homie, a lightweight MQTT convention for the IoT. Main target for Microhomie is the ESP8266 device and has been well tested and used on ESP32.

Microhomie v2 implements Homie v4.0.0.

Read the Microhomie documentation to get started.

If you want to make your own node, learn from our examples until we have a "howto build nodes" section in the documentation or join the #microhomie channel on the MicroPython Slack community and chat with us.

Binaries can be verified with minisign and the following public key:

RWTwPeRvouNzP+mcL1t7QDTnKz96i3Kuf95fjpE28szMq8OTycMmiTzX

MicroPython changes

  • btree support disabled to save some space
  • AccessPoint SSID changed to Microhomie-MAC with the secret microhomiE
  • inisetup.py writes a custom boot.py

Install

Download the latest image and flash it like any MircoPython image to your ESP8266 device. I.E:

esptool --port PORT --baud 460800 write_flash --flash_size=detect --verify -fm dio 0x0 microhomie-esp8266-VERSION.bin

Make your changes in settings.example.py and copy this file as settings.py to your device. You can now test our example nodes from examples/, just copy the main.py to your device. Start with the examples/led node to turn on and off the on-board LED.

Build image

To build your own Microhomie image run:

make bootstrap
make
make delpoy PORT=/dev/ttyUSBX

Known issues

  • No SSL support for now

Included libraries

  • mqtt_as.py by Peter Hinch but we use the patched version from Kevin Köck. Kevins version has support for a keyword based configuration and unsubscribe.
  • asyn.py ('micro' synchronisation primitives for uasyncio) and aswitch.py (Switch and pushbutton classes for asyncio) from Peter Hinch micropython-async repository.
  • uasyncio and uasyncio.core from the MicroPython library repository

About

MicroPython implementation of the Homie MQTT convention for IoT.

https://microhomie.readthedocs.org

License:MIT License


Languages

Language:Python 96.2%Language:Makefile 3.8%