diff --git a/homebridge/README.md b/homebridge/README.md index 768407f2..5cd3ce05 100644 --- a/homebridge/README.md +++ b/homebridge/README.md @@ -25,7 +25,8 @@ This [Homebridge](https://github.com/nfarina/homebridge) plugin provides a platf "password": "abc123!#", "locationIds": ["488e4800-fcde-4493-969b-d1a06f683102", "4bbed7a7-06df-4f18-b3af-291c89854d60"], // OPTIONAL. See below for details "alarmOnEntryDelay": false, // Optional. See below for details - "beamDurationSeconds": 60 // Optional. See below for details + "beamDurationSeconds": 60, // Optional. See below for details + "hideLightGroups": true // Optional. See below for details } ] } @@ -45,6 +46,12 @@ set this option to a specific number of seconds. If this option is not set, the lights will use the duration from the previous time the light was turned on in the Ring app. The maximum value is `32767`, which is ~9.1 hours. +`hideLightGroups`: Ring smart lighting allows you to create lighting groups within the Ring app. +These groups are convenient for detecting motion in an area of your yard and turning on/off all lights +in the group. However, you may wish to group the lights differently in HomeKit and ignore the +groups you have configured in Ring. If this option is `true`, your Ring groups (and their associated motion sensor) +will be ignored and will not show up in HomeKit. + ### Supported Devices * Security Panel * This is a software device that represents the alarm for a Ring location diff --git a/homebridge/config.ts b/homebridge/config.ts index 84146e72..2b55207a 100644 --- a/homebridge/config.ts +++ b/homebridge/config.ts @@ -3,4 +3,5 @@ import { RingAlarmOptions } from '../api' export interface RingAlarmPlatformConfig extends RingAlarmOptions { alarmOnEntryDelay?: boolean beamDurationSeconds?: number + hideLightGroups?: boolean } diff --git a/homebridge/ring-alarm-platform.ts b/homebridge/ring-alarm-platform.ts index d0c48dbf..0e584418 100644 --- a/homebridge/ring-alarm-platform.ts +++ b/homebridge/ring-alarm-platform.ts @@ -1,4 +1,4 @@ -import { RingDevice, RingDeviceType, getLocations } from '../api' +import { getLocations, RingDevice, RingDeviceType } from '../api' import { HAP, hap } from './hap' import { SecurityPanel } from './security-panel' import { BaseStation } from './base-station' @@ -91,7 +91,11 @@ export class RingAlarmPlatform { devices.forEach(device => { const AccessoryClass = getAccessoryClass(device) - if (!AccessoryClass) { + if ( + !AccessoryClass || + (this.config.hideLightGroups && + device.data.deviceType === RingDeviceType.BeamsLightGroupSwitch) + ) { return }