Skip to main content

py-senertec

License: MIT PyPI version

Description

The py-senertec library provides a way to communicate with Senertec Dachsportal2 to monitor your energy unit. This library supports read-only communication. So changing values for your energy unit isn't implemented and not planned.

Requirements

  • Python >=3.10
  • Account for Senertec Dachsportal2/Remeha KWK

Tested with these devices

I could test with these devices but others should also work:

  • Senertec Dachs 0.8
  • Senertec Dachs InnoGen
  • Senertec Dachs Gen2 F5.5
  • Remeha eLecta 300 (technically same as Senertec Dachs 0.8)

Installation

$ pip install py-senertec

Usage

Login and initialization

from senertec.client import senertec
from senertec.canipValue import canipValue
import json

# Initialize class
client = senertec()
# set your callback function for messages
client.messagecallback = self.output
# login
client.login("username", "password")
client.init()

Set the callback function

Once the websocket has been started, data will be transmitted through the websocket. To get the websocket data, you need to add a callback which was done above. The callback function could look like this:

def output(self, value: canipValue):
        print(value.friendlyDataName + ": " +
              value.dataValue.__str__() + value.dataUnit)

Requesting data

units = client.getUnits()
# connect to first unit in the list
client.connectUnit(units[0].serial)
# request all available datapoints from all boards
# This should only be used for testing, it recommended to use a filter instead
# Take a look in the examples folder for a detailed example.
client.request(None)
# logout when you're finished
client.logout()
# or disconnect if you want to connect to another unit afterwards
# client.disconnectUnit()

Errors of energy unit

Errors can also be read out with a simple function. The errors are read out on the connect function and will only be refreshed on a reconnect.

# values are returned directly from function
errors = client.getErrors()

The full example can be found here

If you specify a json string in the request() function you can limit what datapoints should be received. This is recommended if you know what data you want from your heating system e.g. power, temperature. By default all datapoints are included which are more than 400 in most cases and receiving them takes some time and sometimes not every value will be received. This json string should look like this. The json string contains the productGroup at the top and below the datapoints which should be included. You get the productGroup name from the getUnits() function.

You can also optionally include the boardname for a datapoint in the json. This is usefull if a datapoint exists in multiple boards but you only want e.g. AM027 from board SCB-04@1.

What are these datapoints?

Take a look at this manual from Remeha (Page 39). There is already a good explanation of how these datapoints are composed.

Metadata

Release files for py-senertec 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for py-senertec 1.1.0
File Size Uploaded Provenance
py_senertec-1.1.0.tar.gz 11.9 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for py-senertec 1.1.0
File Interpreter ABI Platform
py_senertec-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 26.0 kB

Release files / py_senertec-1.1.0.tar.gz

Download URL py_senertec-1.1.0.tar.gz
Size 11.9 kB
Tags Source
SHA-256 checksum
How to use checksums
4157a45f2a66aa5a6690a070b4a1d5a198f0cdb17565673fa98c7cf65c06b1a1
BLAKE2b-256 checksum
How to use checksums
4c23caf44dfa5166d21402c044f5376664fd5cdb7032111ebfcabfc967a63f29
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Release files / py_senertec-1.1.0-py3-none-any.whl

Download URL py_senertec-1.1.0-py3-none-any.whl
Size 14.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3ef4a9f5360a9d9d6d9967a2d0313178a665a9d3996bcd171d626c86c50579ba
BLAKE2b-256 checksum
How to use checksums
fc5f5fcc19d2eed2d082ef666404fc5eece4f4c4f0ed92f42aba7b4d95451d49
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Security for py-senertec 1.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page