Bluetooth mesh messages library for Python provides parsing and building of Bluetooth Mesh access layer messages as defined in Bluetooth SIG specifications.
This library implements message serialization and deserialization for Bluetooth Mesh protocol, supporting both standard SIG models and Silvair vendor-specific extensions.
https://www.bluetooth.com/specifications/mesh-specifications
Supported models include:
- Generic models: OnOff, Level, Battery, Property
- Lighting models: Lightness, CTL
- Scene model
- Sensor model
- Time model
- Health model
- Config model
- Silvair vendor models: Debug, Debug V2, Emergency Lighting, Emergency Lighting Test, Gateway Config, Light Extended Controller, Network Diagnostic, Network Diagnostic Setup Server, RRule Scheduler
This project requires Python 3.14.
You can install "bluetooth-mesh-messages" via pip from PyPI:
$ pip install bluetooth-mesh-messages
To install the optional Cap'n Proto support, use:
$ pip install "bluetooth-mesh-messages[capnp]"
You can also add it to a Poetry-managed project:
$ poetry add bluetooth-mesh-messages
To include the optional capnp extra with Poetry, use:
$ poetry add bluetooth-mesh-messages --extras capnp
If you want to work on this repository locally, install the project and development dependencies with Poetry:
$ poetry install
Contributions are very welcome. Tests can be run with pytest, please ensure the coverage at least stays the same before you submit a pull request.
Distributed under the terms of the GPL-2.0 license, "bluetooth-mesh-messages" is free and open source software.
If you encounter any problems, please file an issue along with a detailed description.