How dergary/all-in-one-sensor-device works
This repository describes a DIY ESPHome smart-home sensor device, its firmware configurations, automations, and printable enclosure revisions. The intended workflow is local sensing—presence/motion, light, and air quality—followed by lighting or air-quality status automation and Home Assistant integration. The tree documents multiple device generations and connectivity options. Source excerpts only show the custom C4001 component, so links among the broader YAML-defined features are dashed and unverified; README-backed product relationships are cited to the README.
Main entry points: control_leds.yaml Lighting automations · ld2410.yaml Presence and motion · bh1750.yaml Illuminance sensing · bme680.yaml Air and climate sensing
Components 18
Device firmware
- V1 firmware
V1/README.md - V2 firmware
V2/common.yaml - V2.1 firmware
V2.1/device.yaml - Ultimate firmware
Ultimate/device.yaml - Network connectivity
connectivity/wifi.yaml - Thread connectivity
connectivity/thread.yaml
Sensors
- Presence and motion
sensors/ld2410.yaml - Illuminance sensing
sensors/bh1750.yaml - Air and climate sensing
sensors/bme680.yaml - Other sensor configs
sensors - C4001 UART component
components/c4001/c4001.cpp - C4001 control entities
components/c4001/number/__init__.py
Automations
- Lighting automations
automations/control_leds.yaml - Air-quality status
automations/set_air_quality_status_bme680.yaml - Status LED
automations/status_led.yaml
Device hardware
- Printed enclosures
V2.1/models - ESP32 sensor device
Other components
- Home Assistant
Connections 18
- ESP32 sensor device → Home Assistant: integrates with
README.md - ESP32 sensor device → Presence and motion: detects presence
- ESP32 sensor device → Illuminance sensing: measures brightness
- ESP32 sensor device → Air and climate sensing: measures air quality
- ESP32 sensor device → Other sensor configs: uses sensor configs
- ESP32 sensor device → Network connectivity: uses connectivity
- ESP32 sensor device → Thread connectivity: offers connectivity
- C4001 control entities → C4001 UART component: configures
components/c4001/number/__init__.py - C4001 UART component → ESP32 sensor device: runs on ESP32
- Presence and motion → Lighting automations: triggers lighting
- Illuminance sensing → Lighting automations: informs lighting
- Air and climate sensing → Air-quality status: informs status
- Lighting automations → Status LED: controls LEDs
- ESP32 sensor device → Printed enclosures: fits enclosure
- V1 firmware → ESP32 sensor device: defines revision
- V2 firmware → ESP32 sensor device: defines revision
- V2.1 firmware → ESP32 sensor device: defines revision
- Ultimate firmware → ESP32 sensor device: defines revision