Coder Social home page Coder Social logo

sielaff2mqtt's Introduction

sielaff2mqtt

A simple go util to publish the state of a sielaff vending machine to mqtt - for integration into a home assistant installation.

Tested and used in the temporärhaus with a Sielaff (Robimat) GF SiLine M on firmware 0.13.6.

Usage

Compilation:

GOARCH=arm GOARM=7 GOOS=linux go build main.go

Run on the vending machine:

MQTT_BROKER=tcp://192.168.0.10:1883 MQTT_USERNAME=matemat MQTT_PASSWORD=mqttpassword ./main

Features

Currently detecting changes in the following dbus signals:

  • signal path=/; interface=com.sielaff.siline.payment; member=vendEnabled (Vending Enabled)
  • signal path=/; interface=com.sielaff.siline.hmi; member=serviceMenuActivated (Service Menu Active)
  • signal path=/MachineControl; interface=com.sielaff.siline.machine.MachineControl; member=sensorValue (Cooling Temperature)

Publishes the following mqtt topics:

  • homeassistant/binary_sensor/matematvend/config - home assistant mqtt discovery
  • sielaff2mqtt/matematvend/availability
  • sielaff2mqtt/matematvend/state
  • homeassistant/binary_sensor/matematservicemenu/config - home assistant mqtt discovery
  • sielaff2mqtt/matematservicemenu/availability
  • sielaff2mqtt/matematservicemenu/state
  • homeassistant/sensor/matematcoolingtemperature/config - home assistant mqtt discovery
  • sielaff2mqtt/matematcoolingtemperature/availability
  • sielaff2mqtt/matematcoolingtemperature/state

You can change sielaff2mqtt by setting the MQTT_PREFIX environment variable or using the --prefix flag.

TODO

  • Add more sensors
  • Make mqtt device name configurable
  • Implement device part of home assistant mqtt discovery

How to add new sensors

Run dbus-monitor --system on your vending machine and look out for the signal lines.

sielaff2mqtt's People

Contributors

robbi5 avatar

Watchers

Andreas Hubel avatar  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.