Skip to main content

Python API for interacting with Dingz devices

Project description

Python API for interacting with Dingz devices.

This module is not official, developed, supported or endorsed by iolo AG or myStrom AG. For questions and other inquiries, use the issue tracker in this repository please.

Without the support of iolo AG and myStrom AG it would have taken much longer to create this module which is the base for the integration into Home Assistant. Both companies have provided and are still providing hardware, valuable feedback and advice. Their continuous support make further development of this module possible.

See api.dingz.ch for the API details.

Limitations

This module is at the moment limited to consuming sensor data, device details, device configurations and states. The front LED can be controlled but buttons requires you to programm them by yourself.

No support for setting timers and schedules.

Requirements

You need to have Python 3 installed.

  • dingz device

  • Network connection

  • Devices connected to your network

You need to know the IP address of the devices. Please consult your router documentation to get this information or use the dingz CLI tool.

Installation

The package is available in the Python Package Index .

$ pip install dingz

On a Fedora-based system or on a CentOS/RHEL machine which has EPEL enabled.

$ sudo dnf -y install python3-dingz

Module usage

Every unit has its own web interface: http://IP_ADDRESS .

See example.py for detail about module.

How to operate shades / dimmers

d = Dingz("ip_address_or_host")
# Fetch config, this has to be done once to fetch all details about the shades/dimmers
await d.get_devices_config()

# Fetch the current state of the lights/vers
await d.get_state()

# Get details about shade
shade_0 = d.shades.get(0)
print("Blinds: %s Lamella: %s" % (shade_0.current_blind_level(), shade_0.current_lamella_level()))

# Operate shade
shade_0.shade_down()

# Turn on light
d.dimmers.get(2).turn_on(brightness_pct=70)

CLI usage

The package contains a command-line tool which support some basic tasks.

$ dingz discover

License

python-dingz is licensed under ASL 2.0, for more details check LICENSE.

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

dingz-0.5.0.tar.gz (16.6 kB view details)

Uploaded Source

Built Distribution

dingz-0.5.0-py3-none-any.whl (18.1 kB view details)

Uploaded Python 3

File details

Details for the file dingz-0.5.0.tar.gz.

File metadata

  • Download URL: dingz-0.5.0.tar.gz
  • Upload date:
  • Size: 16.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.10.0

File hashes

Hashes for dingz-0.5.0.tar.gz
Algorithm Hash digest
SHA256 6aeea86a1302be018b9f12eed4011ecf3cac9712c2c1e7f0fe1ceeab51aff067
MD5 7c263e25e5395ea347dfca323a384ced
BLAKE2b-256 de9d16d017e1b9f4d1318ffec7f23c5faed55229371c51935e8bf44173964663

See more details on using hashes here.

File details

Details for the file dingz-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: dingz-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 18.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.6.0 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.1 CPython/3.10.0

File hashes

Hashes for dingz-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1f2c48c24c45243f83cb51f1b2b25f5ffac4a06af55de0c6de3d6f52209be3e4
MD5 89aff5bc778823c9dc155a5e68e943aa
BLAKE2b-256 9ddf3e1db297f09e1bdea7655f05c8ea38eaa083af7ec57de4ac45b13533b7d1

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