// Название: NOUS E8 // Модель: E8 // modelID: TS0601 // manufacturerName: _TZE284_0zaf1cr8 const fz = require('zigbee-herdsman-converters/converters/fromZigbee'); const tz = require('zigbee-herdsman-converters/converters/toZigbee'); const exposes = require('zigbee-herdsman-converters/lib/exposes'); const reporting = require('zigbee-herdsman-converters/lib/reporting'); const ota = require('zigbee-herdsman-converters/lib/ota'); const utils = require('zigbee-herdsman-converters/lib/utils'); const globalStore = require('zigbee-herdsman-converters/lib/store'); const e = exposes.presets; const ea = exposes.access; const tuya = require('zigbee-herdsman-converters/lib/tuya'); const definition = { fingerprint: [{modelID: 'TS0601', manufacturerName: '_TZE284_0zaf1cr8'}], model: 'E8', vendor: 'NOUS', description: 'Smoke sensor', fromZigbee: [tuya.fz.datapoints], toZigbee: [tuya.tz.datapoints], configure: tuya.configureMagicPacket, exposes: [ e.smoke(), // Обнаружение дыма e.battery_low(), // Индикация низкого заряда батареи e.battery() // Уровень заряда батареи ], meta: { tuyaDatapoints: [ [1, 'smoke', tuya.valueConverter.trueFalse0], // Датчик дыма [14, 'battery_low', tuya.valueConverter.trueFalse0], // Низкий заряд батареи [15, 'battery', tuya.valueConverter.raw] // Уровень заряда батареи ], }, }; module.exports = definition;