Skip to main content

A parser for Victron BLE messages suitable for use with Home Assistant

Project description

Victron BLE HA Parser

Overview

This project exists solely to provide an interface to the excellent victron-ble project suitable for use with a Home Assistant integration. Thank you to Keshav Varma for maintaining the victron-ble project.

Details

The parser module has one class, VictronBluetoothDeviceData, which parses Bleak advertisements and updates itself with the sensor data from the advertisement. Each instance of VictronBluetoothDeviceData should be fed advertisements from exactly one Victron device (based on the MAC address) and the instance needs to be initiated with the encryption key of the device that is going to be sending updates. If the encryption key is set correctly everything else will be figured out automatically.

There is a handy package from maintainers of the HA project called sensor-state-data to make it easy to automate ingesting sensor state updates like this. Unfortunately, we need to use a unit (amp-hours) not supported by the module and my PR to include amp-hours was rejected because they are not a common unit (https://github.com/Bluetooth-Devices/sensor-state-data/pull/47). For that reason, we need a custom extension of sensor-state-data, which is contained in the custom-sensor-state.py file.

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

victron_ble_ha_parser-0.2.1.tar.gz (8.8 kB view hashes)

Uploaded Source

Built Distribution

victron_ble_ha_parser-0.2.1-py3-none-any.whl (9.7 kB view hashes)

Uploaded Python 3

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