Skip to main content

Casambi Classic BLE Library

PyPI version Python Version License Firmware Fork

A Python library for controlling Casambi lighting devices running Classic firmware via Bluetooth Low Energy (BLE).


Why This Fork? (Classic vs. Evolution)

Casambi networks run on one of two major firmware profiles: Evolution or Classic.

  • Evolution Networks: Newer Casambi installations use the Evolution profile, which has different encryption, UUIDs, and network protocols. Upstream casambi-bt is designed around Evolution.
  • Classic Networks (This Fork's Exclusive Focus): Many existing installations and older Casambi modules remain on Classic firmware. Upgrading is not always feasible or desirable. This fork is tailored to:
    • Communicate with Classic BLE GATT services and characteristics (FE3D and FE4D).
    • Parse Classic passive BLE advertisement frames (Manufacturer ID 0x03C3 / 963) to monitor on/off state and brightness levels without polling.
    • Send direct BLE commands tailored to Classic device firmware (switching, dimming, color temperature, and RGB).
    • Provide optional Casambi Cloud API support for synchronizing network topologies and states.

Features

  • 🎯 Classic-First Architecture: Tailored specifically for Casambi Classic firmware devices.
  • 🔍 BLE Discovery & Scanner: Discover Classic Casambi nodes and decode passive manufacturer advertisement data.
  • 📡 Passive State Tracking: Read on/off and dimming levels directly from BLE advertisements in real-time.
  • 🔌 Direct BLE Control: Connect directly over Bluetooth Low Energy without mandatory cloud intermediaries.
  • 💡 Lighting Controls: Turn lights on/off and set brightness dim levels.
  • 🎨 RGB & Color Temperature: Adjust RGB colors and color temperature (Kelvin).
  • ☁️ Cloud Sync (Optional): Integration with the Casambi Cloud API for session handling and topology inspection.

Installation

pip install casambi-classic-ble

Or from source:

git clone https://github.com/hellqvio86/casambi-classic-ble.git
cd casambi-classic-ble
pip install -e .

Quick Start

import asyncio
from casambi_classic_ble import CasambiScanner

async def main():
    # Scan for Classic Casambi devices
    scanner = CasambiScanner()
    devices = await scanner.scan(duration=5.0)
    
    if devices:
        # Connect to first device
        light = devices[0]
        await light.connect()
        
        # Control the light
        await light.turn_on()
        await light.set_level(unit_id=1, level=0.75)
        await light.set_color_temperature(unit_id=1, temp_kelvin=3000)
        
        # Disconnect
        await light.disconnect()

asyncio.run(main())

Development

Using make:

# Set up development environment (syncs dependencies and installs git hooks)
make setup

# Or install the git commit hook directly
make hooks

# Run tests
make test

# Run linting and checks
make lint

# Run all checks
make all

License

MIT License - see LICENSE file for details.

Author

Olof Hellqvist olof.hellqvist@gmail.com

Metadata

Release files for casambi-classic-ble 0.3.1

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

Source distribution (sdist)

Source distribution for casambi-classic-ble 0.3.1
File Size Uploaded Provenance Actions
casambi_classic_ble-0.3.1.tar.gz 45.4 kB With provenance Details for casambi_classic_ble-0.3.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for casambi-classic-ble 0.3.1
File Interpreter ABI Platform Actions
casambi_classic_ble-0.3.1-py3-none-any.whl Python 3 none any Details for casambi_classic_ble-0.3.1-py3-none-any.whl

Total release size: 96.5 kB

Release files / casambi_classic_ble-0.3.1.tar.gz

Download URL casambi_classic_ble-0.3.1.tar.gz
Size 45.4 kB
Tags Source
SHA-256 checksum
How to use checksums
c3adc63af56f36cd41ce1a463bcf3d912ec8cd03b2e8f824728becfa06aea118
BLAKE2b-256 checksum
How to use checksums
39807de224b4789ace1133033ffc6990498123bb69744a8374b7d3c8e3f90db3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Release files / casambi_classic_ble-0.3.1-py3-none-any.whl

Download URL casambi_classic_ble-0.3.1-py3-none-any.whl
Size 51.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ad26cae87351423e1541721c7d95e8b46f7f7e1037539f6783344931a113005a
BLAKE2b-256 checksum
How to use checksums
504bad44ef9dfe62cbe0be18cb4e38ff69f673c86d824b4cc93995adabd16f7f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

Security for casambi-classic-ble 0.3.1

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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for casambi_classic_ble-0.3.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 31, 2026.

Transparency log

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.

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files Full provenance

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