Newbee request: adding a new device to MQTT

Hi there,

Hopefully you can and are willing to help me a hand. First I have no programming background but I’m curious and willing to learn. So please bear with me.

I’m moving from HUE to HA (on a HA Blue with Conbee 2 dongle). I’m using MQTT and sofar it works fine. At the moment I have mostly Zigbee lamps.

No I want to add a EcoDim duo dimmer that seems to be supported. zigbee2mqtt.io/Eco-Dim.05.md at 4029728e0df39b5017c0b882c5125b9348650205 · Koenkk/zigbee2mqtt.io · GitHub

I found some documentation on adding devices, but I need to see at some place that the Zigbee dimmer is recognized.
My questions:

  1. where can I check that the Zigbee pairing is succesfull?
  2. And do I have to add the device both at HASS config file and the Zigbee2MQTT?

Thanks in advance for your help!

Once zigbee2mqtt add-on is installed, web ui is created. You can add it to the sidebar. You go there to see all your zigbee devices info.

You need to put your device in pairing mode (can’t help with your specific dimmer). You need to allow pairing in zigbee2mqtt web ui by clicking on “Permit join (All)” button and the rest happens automatically. You will have your device added with all the info it exposes.

@MarcinL thanks - I made a mistake with pairing the device. I now see it in MQTT, but with a ‘unsupported’ warning. I guess and have now to proceed with adding it to the config file of MQTT?

And how can I make the device also visible in HASS outside MQTT?

No.
The whole point of Zigbee2MQTT is that devices are added to Hass Automatically. They will appear in the integrations > MQTT page inside Home Assistant.

https://www.zigbee2mqtt.io/devices/Eco-Dim.05.html

When you say you have paired it with and see it in MQTT, are you looking in Zigbee2MQTT or in the MQTT broker, or in the MQTT integration?

I have a Sonoff PIR sensor that will sometimes loose connection and will say unsupported when pairing, I found I have to force remove it from Zigbee2MQTT a few times and repair it and eventually it works, as a rule of thumb if the device is 100% supported within Zigbee2MQTT and you are using the MQTT integration then in theory you shouldn’t need to add any config files anywhere for them to pull in as native devices.

If you monitor the MQTT topic for the device do you see any noise?

The moment I paired, I got this in my Z2M logbook:

Zigbee2MQTT:warn  2022-01-19 23:47:54: Device '0x847127fffed89761' with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV' is NOT supported, please follow https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html
Zigbee2MQTT:warn  2022-01-19 23:48:50: Received message from unsupported device with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV'
Zigbee2MQTT:warn  2022-01-19 23:48:50: Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
(node:365) UnhandledPromiseRejectionWarning: undefined
(node:365) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 24)
Zigbee2MQTT:warn  2022-01-19 23:48:53: Received message from unsupported device with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV'
Zigbee2MQTT:warn  2022-01-19 23:48:53: Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
Zigbee2MQTT:warn  2022-01-19 23:48:57: Received message from unsupported device with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV'
Zigbee2MQTT:warn  2022-01-19 23:48:57: Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
Zigbee2MQTT:warn  2022-01-19 23:48:59: Received message from unsupported device with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV'
Zigbee2MQTT:warn  2022-01-19 23:48:59: Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.
Zigbee2MQTT:warn  2022-01-19 23:49:02: Received message from unsupported device with Zigbee model 'EcoDim-Zigbee 3.0' and manufacturer name 'EcoDim BV'
Zigbee2MQTT:warn  2022-01-19 23:49:02: Please see: https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html.

So, I guess I have to add the device to MQTT

Right. Thanks, just adding the device now

1 Like

Is 3.0 supported? some radios need a newer firmware stack to support 3.0 devices sometimes, when I google that model there are a few different versions of it by the looks of the PCB designs

According to the message in the MQTT log it does. But maybe a firmware update is required. We’ll see.

So, no succes yet. Following Support new devices | Zigbee2MQTT I got stuck:

  1. I created the converter file
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 extend = require('zigbee-herdsman-converters/lib/extend');
const e = exposes.presets;
const ea = exposes.access;

const definition = {
    zigbeeModel: ['EcoDim-Zigbee 3.0'],
    model: 'Eco-Dim.05',
    vendor: 'XEcoDim BV',
    description: 'LED dimmer duo 2x 0-100W',
    extend: generic.light_onoff_brightness,};
module.exports = definition;
  1. I tried several ways to change the config file (Studio code, via the Z2M add-on config and via the setting in the web UI. But in none these ways the config remains the same. (there is a config backup file with the changes, but the actual config file is not changed.
    I tried various options, with and without the default hyphens ("). It should be without, I guess, but none helped.

So, what now?

Then there is most likely something wrong with the formatting changes you are making in the config file… it reverts if not correctly formatted.

Try sharing your Zigbee2mqtt configuration yaml and maybe someone can help find the problem.

Sure. My Z2M config file

{
  external_converters: -Eco-Dim05.js,
  devices: -devices.yaml,
  groups: -groups.yaml,
  homeassistant: true,
  permit_join: true,
  mqtt:
    {
      base_topic: zigbee2mqtt,
      user: addons,
      password: wephoh3aeh1Il6da0iequ2ievu1shuT2Faethahf7aecooZiezae1ahBae3peo7c,
      server: mqtt://core-mosquitto:1883,
    },
  serial: { port: /dev/ttyACM0, adapter: deconz },
  advanced:
    {
      log_level: warn,
      pan_id: 6754,
      channel: 11,
      network_key: [1, 3, 5, 7, 9, 11, 13, 15, 0, 2, 4, 6, 8, 10, 12, 13],
      availability_blocklist: [],
      availability_passlist: [],
    },
  device_options: {},
  blocklist: [],
  passlist: [],
  queue: {},
  frontend: { port: 8099 },
  experimental: {},
}

Device data: EcoDim Eco-Dim.05 control via MQTT | Zigbee2MQTT

Everything that I can find in the Github issues, suggests that you need to remove this device. Move it RIGHT NEXT to the coordinator (USB Stick), and then go through the pairing process again.

You do not need to edit any files, because it is already a supported device. It was probably just too far away from the coordinator for the interview to complete properly.

If however you DID have to edit the file:

extend: generic.light_onoff_brightness,};

The comma here, means JSON is expecting there to be another key:value pair, and there isn’t one because } ends that object. This is therefore not valid JSON.

vendor: 'XEcoDim BV',

Should actually match the vendor, the capital X here, is probably a typo - but in either case, it means it won’t match the device.

And I believe:

external_converters: -Eco-Dim05.js,

Should be:

external_converters: ['-Eco-Dim05.js'],

Because it should be an array of external converters even if there is only one.

But like I say - the device should absolutely be supported - because it is here:

Thanks @mobile.andrew.jones for the extensive reply.
Unfortunately the changes you suggested didn’t make a difference unfortunately.

However, I can also use the EcoDim converter you linked to.
Do I than still have to make changes in the config file and point to this converter?