Git Product home page Git Product logo

knx.js's Introduction

KNXnetIP (KNX over IP) deriver for nodejs.

Based on https://github.com/lifeemotions/knx.net

Right now it not tested in all directions, but KnxConnectionTunneling is working. One can find Usage example, it tested with KNXnet/IP router: ABB IPR/S 2.1.

Install

  • go to npm's package dir
  • npm i knx.js --save
  • or yarn add knx.js --save

Usage

const KnxConnectionTunneling = require('knx.js').KnxConnectionTunneling;
let connection = new KnxConnectionTunneling('192.168.2.222', 3671, '192.168.2.107', 13671);

connection.on('event', event => console.log('Event received', event));
connection.on('status', status => console.log('Status received', status));

let lightValue = false;
const toggleLight = () => {
  lightValue = !lightValue;
  connection.Action('1/0/0', lightValue);
};

connection.Connect(function () {
  setTimeout(toggleLight, 2000);
  setTimeout(toggleLight, 5000);
  setTimeout(() => connection.Disconnect(), 7000);
});

License

Attribution-NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0)

knx.js's People

Contributors

aborovsky avatar ykornilov avatar pkess avatar s0meone avatar

Stargazers

 avatar Afif Abdillah Jusuf avatar  avatar Mehmet Akif DERE avatar  avatar  avatar pedall avatar Evgeny Gazdovsky avatar Erik Hennig avatar Marcel avatar Adrian Scillato avatar  avatar Panagiotis Tzamtzis avatar Perry avatar Vladimir Shabunin avatar Mario Übleis avatar Mattias Holmlund avatar Elias Karakoulakis avatar  avatar Motaz Abuthiab avatar  avatar Claus Klingberg avatar  avatar

Watchers

Claus Klingberg avatar Mario Übleis avatar Elias Karakoulakis avatar Mattias Holmlund avatar James Cloos avatar Sergey Klenov avatar  avatar  avatar Adrian Scillato avatar  avatar

knx.js's Issues

Floating point values not working

The 2 octet data type for floating point values (DPT 9.00x) is not working properly. This makes reading of temperature values problematic. Any plans to fix this?

Full example

hello,

I'm very interested in this subject.
Do you have a full example of the code for me to refer to?
Would be a great help.

Thanks!

Error when multiple commands executed in small time frame

Hi, I get this error when multiple commands executed in small time frame:

Error: Not running
at Socket._healthCheck (dgram.js:421:11)
at Socket.send (dgram.js:273:8)
at KnxSenderTunneling.SendData (knx.js/src/KnxSenderTunneling.js:43:21)
at KnxSenderTunneling.KnxSender.Action (knx.js/src/KnxSender.js:9:10)
at KnxConnectionTunneling.KnxConnection.Action (knx.js/src/KnxConnection.js:119:20)

BTW, is this project still alive? I would like to use it in long term for my home automation needs.

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.