Skip to content

Commit

Permalink
feat(add): SM0202 Koenkk/zigbee2mqtt#15772
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenkk committed May 24, 2023
1 parent 2b45558 commit fcb9c1e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 14 deletions.
14 changes: 0 additions & 14 deletions src/devices/cleverio.js
Expand Up @@ -33,18 +33,4 @@ module.exports = [
toZigbee: [],
configure: tuya.configureMagicPacket,
},
{
fingerprint: [{modelID: 'SM0202', manufacturerName: '_TYZB01_z2umiwvq'}],
model: 'SS200',
vendor: 'Cleverio',
description: 'Smart motion sensor',
fromZigbee: [fz.ias_occupancy_alarm_1_with_timeout, fz.battery, fz.ignore_basic_report],
toZigbee: [],
exposes: [e.occupancy(), e.battery_low(), e.linkquality(), e.battery(), e.battery_voltage()],
configure: async (device, coordinatorEndpoint, logger) => {
const endpoint = device.getEndpoint(1);
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
await reporting.batteryPercentageRemaining(endpoint);
},
},
];
18 changes: 18 additions & 0 deletions src/devices/tuya.js
Expand Up @@ -5305,4 +5305,22 @@ module.exports = [
tuya.whitelabel('UseeLink', 'SM-O301-AZ', 'AU 4 plug 10A power board + USB', ['_TZ3000_o005nuxx']),
],
},
{
zigbeeModel: ['SM0202'],
model: 'SM0202',
vendor: 'TuYa',
description: 'Motion sensor',
fromZigbee: [fz.ias_occupancy_alarm_1_with_timeout, fz.battery],
toZigbee: [],
exposes: [e.occupancy(), e.battery_low(), e.linkquality(), e.battery(), e.battery_voltage()],
configure: async (device, coordinatorEndpoint, logger) => {
const endpoint = device.getEndpoint(1);
await reporting.bind(endpoint, coordinatorEndpoint, ['genPowerCfg']);
await reporting.batteryPercentageRemaining(endpoint);
},
whiteLabel: [
tuya.whitelabel('Cleverio', 'SS200', 'Motion sensor', ['_TYZB01_z2umiwvq']),
tuya.whitelabel('Marmitek', 'SM0202_1', 'Motion sensor', ['_TYZB01_yr95mpib']),
],
},
];

0 comments on commit fcb9c1e

Please sign in to comment.