Skip to main content

Python library to provide connect to Genius Hub on a local network.

Reason this release was yanked:

deprecated

Project description

GeniusHub

Python library to provide connect to Genius Hub on a local network.

Installation

Either clone this resposition and run python setup.py install, or install from pip using pip install genius.

API

This library makes use of the undocumented API for communicating to the Genius Hub. This API may change with future updates to the Genius Hub Firmware.

The library supports the following functions:

getClimateList()
getSwitchList()
getTRVList()
getSensorList()
getSwitchList()
getZone(zoneId)
getDevice(zoneId, addr)
GET_CLIMATE(zone)
GET_SWITCH(zone)
getSensor(cv)
getTRV(cv)
GET_MODE(zone)
putjson(device_id, data)

Usage

Initialise a link to the hub by passing in the local IP address, username and password. The username and password are the same that you use to log into your Genius application. Once logged in successfully the module will poll the hub at regular intervals so that getting values from the hub will be cached locally.

What is read from the getters is self explanatory. The putjson POST the data to the Genius Hub. The format of the json can be discovered by exploring the Genius application and view the requests posted to the hub.

import asyncio
from geniushub import GeniusHub

IP_ADDRESS = 'Your local ip address'
USERNAME = 'Your user name'
PASSWORD = 'Your password'
INTERVAL = 60


async def main():
    genius_hub = GeniusHub(IP_ADDRESS, USERNAME, PASSWORD, INTERVAL)
    await genius_hub.getjson('/zones')

    # Get the zones with a temperature
    climate_list = genius_hub.getClimateList()

    print("Climate -------------------------------------------------------------")
    for zone in climate_list:
        print(zone)

    trvs = genius_hub.getTRVList()

    print("TRV -----------------------------------------------------------------")
    for trv in trvs:
        print(trv)

    switches = genius_hub.getSwitchList()

    print("Switches ------------------------------------------------------------")
    for switch in switches:
        print(switch)

    sensors = genius_hub.getSensorList()

    print("Sensors -------------------------------------------------------------")
    for sensor in sensors:
        print(sensor)

loop = asyncio.get_event_loop()
loop.run_until_complete(main())
loop.close()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geniushub-0.1.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

geniushub-0.1-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file geniushub-0.1.tar.gz.

File metadata

  • Download URL: geniushub-0.1.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.19.1 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3

File hashes

Hashes for geniushub-0.1.tar.gz
Algorithm Hash digest
SHA256 5dc12c71f805b9bbf99b6138c758ca4c87deb3b124b504d3c5dcdf6dbb2952b2
MD5 475fbd786c3d84a80be036a6cfb019a2
BLAKE2b-256 f8d89629b59054a532f1162a244c81c18800fc588b2f0642ecb6f282e12724d4

See more details on using hashes here.

File details

Details for the file geniushub-0.1-py3-none-any.whl.

File metadata

  • Download URL: geniushub-0.1-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.19.1 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.3

File hashes

Hashes for geniushub-0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7e61f9eca99b85cc06def01ed4b7b83dd6f8fbc67640008238f4cd0e20d3965e
MD5 868988ba3008f20b1f56cda154c500b2
BLAKE2b-256 5b251aa433b418823f0615a397c28f7f415f34556ae8380ac5b07cd91041b50e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page