Code Monkey home page Code Monkey logo

xknx's Introduction

XKNX - An Asynchronous KNX Library Written in Python

codecov Checked with mypy Pre-commit

Documentation

See documentation at: https://xknx.io/

Help

We need your help for testing and improving XKNX. For questions, feature requests, bug reports either join the XKNX chat on Discord or write an email.

Development

You will need at least Python 3.8 in order to use XKNX.

Setting up your local environment:

  1. Install requirements: pip install -r requirements/testing.txt
  2. Install pre-commit hook: pre-commit install

Home-Assistant Plugin

XKNX contains a plugin for the Home Assistant automation platform

Example

"""Example for switching a light on and off."""
import asyncio
from xknx import XKNX
from xknx.devices import Light

async def main():
    """Connect to KNX/IP bus, switch on light, wait 2 seconds and switch it off again."""
    async with XKNX() as xknx:
        light = Light(xknx,
                      name='TestLight',
                      group_address_switch='1/0/9')
        await light.set_on()
        await asyncio.sleep(2)
        await light.set_off()

asyncio.run(main())

xknx's People

Contributors

julius2342 avatar farmio avatar marvin-w avatar dependabot-preview[bot] avatar dependabot[bot] avatar basilfx avatar twistermcneal avatar magenbrot avatar spacegaier avatar encbladexp avatar rnixx avatar jochembroekhoff avatar extenzy avatar itineric avatar drmurx avatar straeng avatar knxbroker avatar crazyfx1 avatar buergi avatar oliverblaha avatar recmartin avatar arnonym avatar elupus avatar bachp avatar tombbo avatar phbaer avatar amp-man avatar cyberjunky avatar roemer avatar mielune 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.