Skip to content

Add general Radar Zone Occupancy sensor#74

Merged
bharvey88 merged 1 commit intobetafrom
add-radar-zone-occupancy
Mar 4, 2026
Merged

Add general Radar Zone Occupancy sensor#74
bharvey88 merged 1 commit intobetafrom
add-radar-zone-occupancy

Conversation

@bharvey88
Copy link
Contributor

@bharvey88 bharvey88 commented Mar 4, 2026

Version: 26.3.2.1

What does this implement/fix?

Adds a consolidated "Radar Zone Occupancy" binary sensor that aggregates the three individual zone occupancy sensors (Zone 1, Zone 2, Zone 3) into a single unified sensor. This makes it easier to write automations that simply check "is there a person in this room?" without referencing individual zone sensors.

Mirrors the same addition made in MSR-2 (ApolloAutomation/MSR-2#47).

Types of changes

  • Bugfix (fixed change that fixes an issue)
  • New feature (thanks!)
  • Breaking change (repair/feature that breaks existing functionality)
  • Dependency Update - Does not publish
  • Other - Does not publish
  • Website of github readme file update - Does not publish
  • Github workflows - Does not publish

Checklist / Checklijst:

  • The code change has been tested and works locally
  • The code change has not yet been tested

If user-visible functionality or configuration variables are added/modified:

  • Added/updated documentation for the web page

Summary by CodeRabbit

  • New Features
    • Added Radar Zone Occupancy sensor that aggregates occupancy detection across all radar zones, providing a unified occupancy state for streamlined automation and monitoring.

Adds a consolidated binary sensor that aggregates zone 1, 2, and 3
occupancy into a single sensor for simpler automations.
@coderabbitai
Copy link

coderabbitai bot commented Mar 4, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: abf85505-bcbc-4cdd-8783-221c8358c285

📥 Commits

Reviewing files that changed from the base of the PR and between 6b34d27 and d0f92b2.

📒 Files selected for processing (1)
  • Integrations/ESPHome/Core.yaml

Walkthrough

Added a new template binary_sensor called "Radar Zone Occupancy" to the ESPHome configuration that aggregates occupancy data from three radar zone sensors using logical OR. The sensor includes device classification, icon assignment, and lambda logic combining existing sensors, with minor formatting adjustments to pin configuration.

Changes

Cohort / File(s) Summary
ESPHome Configuration
Integrations/ESPHome/Core.yaml
Added new template binary_sensor radar_zone_occupancy that aggregates occupancy states from Radar Zone 1/2/3 sensors using lambda OR logic. Includes device class (occupancy), icon (mdi:motion-sensor), and minor GPIO pin formatting adjustment.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 Three zones now speak with one voice clear,
A motion-sensing ear to hear,
Where occupancy aggregates with care,
Rabbits approve of sensors fair! 🎯

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title accurately summarizes the main change: adding a consolidated Radar Zone Occupancy sensor that aggregates three zone occupancy sensors.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add-radar-zone-occupancy

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions bot requested a review from TrevorSchirmer March 4, 2026 18:53
@bharvey88
Copy link
Contributor Author

confirmed working with discord user hobbyboy merging to beta to test further

@bharvey88 bharvey88 merged commit d67740a into beta Mar 4, 2026
12 checks passed
@bharvey88 bharvey88 deleted the add-radar-zone-occupancy branch March 4, 2026 21:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new-feature New feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants