diff --git a/converters/fromZigbee.js b/converters/fromZigbee.js index 08ff4c0fb4033..b95db29e9e33a 100644 --- a/converters/fromZigbee.js +++ b/converters/fromZigbee.js @@ -1336,6 +1336,18 @@ const converters = { }; }, }, + bosch_ias_zone_motion_status_change: { + cid: 'ssIasZone', + type: 'statusChange', + convert: (model, msg, publish, options) => { + const zoneStatus = msg.data.zoneStatus; + return { + occupancy: (zoneStatus & 1) > 0, // Bit 0 = Alarm 1: Presence Indication + tamper: (zoneStatus & 1<<2) > 0, // Bit 2 = Tamper status + battery_low: (zoneStatus & 1<<3) > 0, // Bit 3 = Battery LOW indicator (trips around 2.4V) + }; + }, + }, ias_contact_dev_change: { cid: 'ssIasZone', type: 'devChange', diff --git a/devices.js b/devices.js index 6e6aee7e7ac3d..f3e71b523619f 100644 --- a/devices.js +++ b/devices.js @@ -2393,6 +2393,33 @@ const devices = [ toZigbee: [tz.livolo_switch_on_off], }, + // Bosch + { + zigbeeModel: ['RFDL-ZB-MS'], + model: 'RADON TriTech ZB', + vendor: 'Bosch', + description: 'Wireless motion detector', + supports: 'occupancy and temperature', + fromZigbee: [ + fz.generic_temperature, fz.ignore_temperature_change, fz.generic_batteryvoltage_3000_2500, + fz.ignore_power_change, fz.bosch_ias_zone_motion_status_change, fz.ignore_iaszone_change, + ], + toZigbee: [], + configure: (ieeeAddr, shepherd, coordinator, callback) => { + const device = shepherd.find(ieeeAddr, 1); + const actions = [ + (cb) => device.write('ssIasZone', 'iasCieAddr', coordinator.device.getIeeeAddr(), cb), + (cb) => device.functional('ssIasZone', 'enrollRsp', {enrollrspcode: 0, zoneid: 23}, cb), + (cb) => device.bind('msTemperatureMeasurement', coordinator, cb), + (cb) => device.report('msTemperatureMeasurement', 'measuredValue', 60, 58000, 1, cb), + (cb) => device.bind('genPowerCfg', coordinator, cb), + (cb) => device.report('genPowerCfg', 'batteryVoltage', 1800, 3600, cb), + ]; + + execute(device, actions, callback); + }, + }, + // Immax { zigbeeModel: ['IM-Z3.0-DIM'],