I'm running Zigbee2mqtt with Domoticz and I've made a soil moisture sensor using a CC2530 and a capacitive sensor, inspired by this example https://community.home-assistant.io/t/d ... sor/251031
The board is flashed with the ptvo firmware and the device is recognized in Domoticz by the auto discovery plugin. using this external coverter:
Code: Select all
const zigbeeHerdsmanConverters = require('zigbee-herdsman-converters');
const exposes = zigbeeHerdsmanConverters.exposes;
const ea = exposes.access;
const e = exposes.presets;
const fz = zigbeeHerdsmanConverters.fromZigbeeConverters;
const tz = zigbeeHerdsmanConverters.toZigbeeConverters;
const ptvo_switch = zigbeeHerdsmanConverters.findByDevice({modelID: 'ptvo.switch'});
fz.legacy = ptvo_switch.meta.tuyaThermostatPreset;
const device = {
zigbeeModel: ['Bodemvochtigheid'],
model: 'Bodemvochtigheid',
vendor: 'Custom devices (DiY)',
description: 'Configurable firmware',
fromZigbee: [fz.ignore_basic_report, fz.ptvo_switch_analog_input,],
toZigbee: [tz.ptvo_switch_trigger, tz.ptvo_switch_analog_input,],
exposes: [e.voltage().withAccess(ea.STATE).withValueMin(0).withValueMax(3.3).withEndpoint('l1'),
],
meta: {
multiEndpoint: true,
},
endpoint: (device) => {
return {
l1: 1,
};
},
};
module.exports = device;
Is there anyone who can help me or point me in the right direction..?
All help is much appreciated!