This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

A minimalistic KNX / EIB python library.

Sending telegrams

This library can be used to send data telegrams to actuators in the bus system.

For example in order to turn on a light the following code could be used:

>>> from knx import connect
>>> with connect() as c:
...     c.write('0/1/14', 1)

Where 0/1/14 is the address of the light and 1 is the payload of the data telegram which indicates that the light should be turned on.

Listening to telegrams

This KNX library can also be used to listen to telegrams that are sent onto the bus system. For example if you simply want to log an entry each time a light is turned off or on:

>>> import knx
>>> import asyncio

>>> @knx.coroutine
... def logger():
...     while True:
...         telegram = (yield)
...         print('Telegram from {0} sent to {1} with value: {2}'.format(
...               telegram.src, telegram.dst, telegram.value))

>>> loop = asyncio.get_event_loop()
>>> coro = knx.bus_monitor(logger(), host='localhost', port=6720)
>>> loop.run_until_complete(coro)

Install & Requirements

  • Python >= 3.4

Install using pip:

$ pip install knx

Disclaimer

I’ve only tested this with eibd 0.0.5 and the fork knxd as a gateway.

Alternatives

If you’re looking for complete home automation solutions you might want to take a look at home-assistant or smarthome.

Development

Edit knx.py in your favorite editor and run tests using python -m unittest or python tests.py.

If you want to run the examples without first installing this library you can use:

python -m examples.actor -- hostname '0/0/20'

(Replace actor with the appropriate module name and omit the arguments if the module doesn’t require them)

Release History

Release History

0.3.0

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.2.0

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.3

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.2

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
knx-0.3.0-py2.py3-none-any.whl (7.0 kB) Copy SHA256 Checksum SHA256 py2.py3 Wheel Feb 6, 2016
knx-0.3.0.tar.gz (7.6 kB) Copy SHA256 Checksum SHA256 Source Feb 6, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting