Giter Club home page Giter Club logo

loxone2mqtt's Introduction

loxone2mqtt

mqtt-smarthome NPM version Dependency Status Build Status js-semistandard-style License: MIT Docker Build Status

Gateway for Loxone™ miniserver to communicate with mqtt broker with the https://github.com/mqtt-smarthome topic and payload format.

This is a fork of node-lox-mqtt-gateway (c) 2016 Ladislav Dokulil , heavily modified and rewritten to suite my needs.

Notable changes:

For communication with miniserver is used WebSocket api described in [Loxone™ API Documentation] (https://www.loxone.com/enen/kb/api/)

Preamble

This is experimental version.

Use it at your own risk.

Quick start

Gateway for Loxone™ miniserver to communicate with mqtt broker

Usage: loxone2mqtt.js [options]

Optionen:
  -v, --verbosity  possible values: "error", "warn", "info", "debug"
                                                              [Standard: "info"]
  -n, --name       instance name. used as mqtt client id and as prefix for
                   connected topic                             [Standard: "lox"]
  -u, --url        mqtt broker url. See
                   https://github.com/mqttjs/MQTT.js#connect-using-a-url
                                                  [Standard: "mqtt://127.0.0.1"]
  -p, --password   Loxone passcode
  -l, --loxone     Loxone host
  -i, --userid     Loxone user id
  -h, --help       Hilfe anzeigen                                      [boolean]
  --version        Version anzeigen                                    [boolean]

MQTT Interface

MQTT topic base

{name}/{state|set|meta}/category/room/control_name/

example

lox/state/light/bedroom/main_light

States of Loxone™ miniserver to MQTT

If you tries to get the state of specific control you need to subscribe

topic

mqtt_prefix/{state|set}/category/room/control_name/

message contains data

in JSON format.

TODO: Make documentation for all controls

MQTT to Loxone™ miniserver actions

If you could make some action you must publish message with:

topic

mqtt_prefix/set/category/room/control_name/

data

There is a command string like in Loxone™ API Structure file documentation

example of whole message (todo)

{
    "topic": "lox/set/light/bedroom/main_light",
    "val": 1
}

Build and run local Docker container

docker build -t loxone2mqtt .

docker run --env-file ./loxone.env -i loxone2mqtt 

With an loxone.env file

LOXONE_url=mqtt://localhost
LOXONE_userid=admin
LOXONE_password=password
LOXONE_loxone=loxone.local

loxone2mqtt's People

Contributors

alladdin avatar hobbyquaker avatar krambox avatar kramerempolis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

hobbyquaker

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.