-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Mercator Ikuu Combination Sensor SSWM-PIR-ZB #7918
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -5,6 +5,7 @@ import * as reporting from '../lib/reporting'; | |||||
import * as tuya from '../lib/tuya'; | ||||||
import {Definition} from '../lib/types'; | ||||||
const e = exposes.presets; | ||||||
const ea = exposes.access; | ||||||
|
||||||
const definitions: Definition[] = [ | ||||||
{ | ||||||
|
@@ -213,6 +214,43 @@ const definitions: Definition[] = [ | |||||
device.save(); | ||||||
}, | ||||||
}, | ||||||
{ | ||||||
fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE200_agumlajc'}], | ||||||
model: 'SSWMPIR-ZB', | ||||||
vendor: 'Mercator Ikuü', | ||||||
description: 'Combination Sensor', | ||||||
fromZigbee: [fz.occupancy, fz.temperature, fz.humidity, fz.illuminance, fz.on_off, tuya.fz.datapoints], | ||||||
toZigbee: [tuya.tz.datapoints], | ||||||
exposes: [ | ||||||
e.occupancy(), e.temperature(), e.humidity(), e.illuminance(), e.light(), | ||||||
e.enum('state', ea.STATE_SET, ['ON', 'OFF', 'AUTO']).withDescription('Light Mode') | ||||||
], | ||||||
configure: async (device, coordinatorEndpoint, logger) => { | ||||||
const endpoint = device.getEndpoint(1); | ||||||
await reporting.bind(endpoint, coordinatorEndpoint, ['genBasic', 'genOta', 'genTime', 'genGroups', 'genScenes']); | ||||||
await reporting.bind(endpoint, coordinatorEndpoint, ['genIdentify', 'manuSpecificTuya']); | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Are these binds really needed? Can you check after removing them and re-pairing the device, the device still works? |
||||||
}, | ||||||
meta: { | ||||||
// All datapoints go in here | ||||||
tuyaDatapoints: [ | ||||||
[1, 'temperature', tuya.valueConverter.divideBy10], | ||||||
[2, 'humidity', tuya.valueConverter.raw], | ||||||
//[10, ], | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please remove all |
||||||
//[11, ], | ||||||
//[12, ], | ||||||
//[13, ], | ||||||
[101, 'illuminance', tuya.valueConverter.raw ], //illuminance | ||||||
//[102, ], | ||||||
//[103, ], | ||||||
[104, 'occupancy', tuya.valueConverter.trueFalse1], | ||||||
[105, 'state', tuya.valueConverterBasic.lookup({'ON': tuya.enum(0), 'OFF': tuya.enum(1), 'AUTO': tuya.enum(2)}) ] //Light motion setting | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
//[106, ], | ||||||
//[107, ], | ||||||
//[108, ], | ||||||
//[109, ], | ||||||
], | ||||||
}, | ||||||
}, | ||||||
]; | ||||||
|
||||||
export default definitions; | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please test if it also works with just this