Skip to content

Add support for Corentium Home 2 and Renew - #91

Merged
michaelahern merged 4 commits into
michaelahern:mainfrom
LaStrada:feature/add-corentium-home-2-and-renew
Apr 25, 2026
Merged

Add support for Corentium Home 2 and Renew#91
michaelahern merged 4 commits into
michaelahern:mainfrom
LaStrada:feature/add-corentium-home-2-and-renew

Conversation

@LaStrada

Copy link
Copy Markdown
Contributor

Renew doesn't have batteries, so added a battery config as well.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds device metadata and service-selection logic to support additional Airthings models (Corentium Home 2 and Renew), including handling devices that do not report battery data.

Changes:

  • Add new device serial prefixes (3250, 4100) and introduce a sensors.battery capability flag in AirthingsDeviceInfo.
  • Only expose the HomeKit Battery service when the device is marked as having a battery and the user hasn’t disabled it.
  • Update README supported-devices table to include the new models.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
src/plugin.ts Gates Battery service exposure behind device.sensors.battery + existing batteryDisabled config.
src/device.ts Adds battery capability to sensor metadata and new mappings for Corentium Home 2 / Renew prefixes.
README.md Adds Corentium Home 2 and Renew to the supported devices table and fixes table formatting.
Comments suppressed due to low confidence (1)

src/device.ts:178

  • In the default device mapping, sensors.battery is set to false, which means the Battery service will no longer be exposed for any unrecognized serial prefixes (even if the Airthings API returns batteryPercentage). Previously, battery was shown for all devices unless batteryDisabled was set. Consider defaulting battery to true for Unknown, or deriving battery support from API data so unknown-but-compatible devices don’t regress.
            return {
                model: 'Unknown',
                sensors: {
                    battery: false,
                    co2: false,
                    humidity: false,
                    mold: false,
                    pm1: false,
                    pm25: false,
                    pressure: false,
                    radonShortTermAvg: false,
                    temp: false,
                    voc: false
                }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/plugin.ts
Comment thread README.md
@michaelahern
michaelahern merged commit db240d9 into michaelahern:main Apr 25, 2026
8 checks passed
@michaelahern

Copy link
Copy Markdown
Owner

Thanks for the contribution @LaStrada!

@LaStrada
LaStrada deleted the feature/add-corentium-home-2-and-renew branch April 28, 2026 07:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants