Skip to main content

Zigbee integration for MajorDom — bridges Zigbee devices into the MajorDom language.

Project description

integration-zigbee

A MajorDom integration — bridges Zigbee devices into the MajorDom language.

Built for the MajorDom Hub, but it doesn't need it: this is a standalone, standardized library for Zigbee that you can use on its own (see Run it standalone below). Built on the MajorDom Integration SDK. The entry point is ZigBeeController (majordom_zigbee/controller.py), which the Hub — or the SDK's dev runner — instantiates and drives through its lifecycle: pairing → commands → teardown.

Documentation

Full integration-author docs — the controller lifecycle, data models, storing data, discovery, and a worked example — live at docs.majordom.io.

Development

poetry install && poetry run poe install
Task Description
poe check Full quality pipeline (ruff, ty, pytest, poetry build/check)
poe check --ci Same, plus git diff --exit-code

Work lands on develop; master is protected and released via Actions → Release. Tests drive the controller with the SDK's test doubles against a simulated zigpy device — no radio required (see tests/).

Run it standalone (without the Hub)

Zigbee needs a physical 802.15.4 radio (a Zigbee coordinator such as a SkyConnect, ConBee, or a zigpy-znp/bellows-supported dongle) at a serial path. Then:

# run.py
import asyncio

from majordom_integration_sdk.dev import run_controller
from majordom_zigbee import ZigBeeController

# Opens the network, watches for joining devices, logs events. Ctrl-C to stop.
asyncio.run(run_controller(ZigBeeController, db_path="devices.db"))
poetry run python run.py

About this integration

  • Protocol / platform: Zigbee via zigpy (with bellows / zigpy-znp radio libraries).
  • Transport(s): Zigbee (IEEE 802.15.4).
  • Supported devices: Zigbee Home Automation devices — lights, plugs, switches, sensors.
  • Credentials needed to pair: none — devices join during an explicit pairing window.

Required harness

  • Hardware adapters: a Zigbee coordinator radio (SkyConnect / ConBee / a zigpy-supported dongle) — the Hub assigns its OS device path via dependencies.hardware_interfaces (e.g. /dev/ttyACM0).
  • Third-party software services: none — zigpy speaks to the radio directly.
  • OS / permissions: serial-port access to the radio.

Protocol stack (OSI)

OSI layer Protocol Implemented by
Application (7) Zigbee Cluster Library (ZCL) this integration (via zigpy)
Network (3) Zigbee NWK / APS library (zigpy · radio firmware)
Data link / Physical (1–2) IEEE 802.15.4 radio adapter (harness)

Progress

  • start_pairing_window implemented (Zigbee requires an explicit join window)
  • Discovery of joining devices; controller_did_receive_discovery called
  • Re-discovery of already-paired devices on reconnect (controller_did_connect_device)
  • Device pairing
  • Device schema mapped: endpoints/clusters → parameter list with per-parameter metadata
  • Hub → Device control (send_command — commands and attribute writes)
  • Device → Hub event subscription (controller_did_receive_events)
  • identify
  • unpair
  • fetch
  • Availability tracking while running (controller_did_lose_device / last_error)
  • Graceful shutdown in stop
  • Tests pass against a simulated zigpy device (tests/)

Notes

The device/parameter ids are derived from the device's IEEE address via the SDK's UUID helpers, so they're stable across restarts and namespaced per integration.

License

See LICENSE. For commercial licensing or partnership inquiries regarding MajorDom, contact us via parker-industries.org/partnership.

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

majordom_zigbee-0.1.2.tar.gz (22.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

majordom_zigbee-0.1.2-py3-none-any.whl (23.9 kB view details)

Uploaded Python 3

File details

Details for the file majordom_zigbee-0.1.2.tar.gz.

File metadata

  • Download URL: majordom_zigbee-0.1.2.tar.gz
  • Upload date:
  • Size: 22.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for majordom_zigbee-0.1.2.tar.gz
Algorithm Hash digest
SHA256 5d44a3c59dd110d672ba4468e02bf6383519af86d6dc8bdef8383ea8cd19271a
MD5 2ad89e60db799c5af5e37697787c89ac
BLAKE2b-256 842db21992b943f19cf0d9d428c936f95e8eaca8ff316482ca0f7b7b3f279b4f

See more details on using hashes here.

Provenance

The following attestation bundles were made for majordom_zigbee-0.1.2.tar.gz:

Publisher: release.yml on MajorDom-Systems/integration-zigbee

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file majordom_zigbee-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: majordom_zigbee-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 23.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for majordom_zigbee-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 de444099c2716c8ad899981022b6e06949bdb2ddabc0cd5a91990e047aa0c12b
MD5 197756c09291be756ee63cf6729852a9
BLAKE2b-256 cca589107a9fc0b02982ccd7e51d84d2e96a64a8adb6121b216b8414d4aa9351

See more details on using hashes here.

Provenance

The following attestation bundles were made for majordom_zigbee-0.1.2-py3-none-any.whl:

Publisher: release.yml on MajorDom-Systems/integration-zigbee

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page