Zigbee2mqtt - unsupported device integration

Hello,
I tried to integrate unsupported Immax 07703L into Zigbee2mqtt using custom devices.js. I copy device ETOP HT-10 which looks physically exactly the same with the same functions as Immax 07703L.

    {
        zigbeeModel: ['losfena'], 
        model: '07703L',
        vendor: 'Immax',
        description: 'Radiator valve',
        supports: 'thermostat, temperature',
        fromZigbee: [
            fz.tuya_thermostat_weekly_schedule,
            fz.etop_thermostat,
            fz.ignore_basic_report,
            fz.tuya_ignore_set_time_request, // handled in onEvent
        ],
        toZigbee: [
            tz.etop_thermostat_system_mode,
            tz.etop_thermostat_away_mode,
            tz.tuya_thermostat_child_lock,
            tz.tuya_thermostat_current_heating_setpoint,
            tz.tuya_thermostat_weekly_schedule,
        ],
        onEvent: tuya.setTime,
        meta: {
            timeout: 20000, // TRV wakes up every 10sec
            thermostat: {
                weeklyScheduleMaxTransitions: 4,
                weeklyScheduleSupportedModes: [1], // bits: 0-heat present, 1-cool present (dec: 1-heat,2-cool,3-heat+cool)
                weeklyScheduleFirstDayDpId: 101,
            },
        },
    },

Now I can see all the actual values in Zigbee2mqtt log. Problem is that this values were not added to my Entities, as well as I cannot see this new device in Devices. Is there some additionall settings about auto discovery or something? I am using HassOs on Raspberry PI 4. Many thanks.

1 Like

I didn´t find way how to discover devices automatically, so I did manual integration in congfiguration.yaml:

sensor:
  - platform: "mqtt"
    name: Topení koupelna - kvalita signálu
    state_topic: "zigbee2mqtt/Topení koupelna"
    availability_topic: "zigbee2mqtt/bridge/state"
    icon: "mdi:signal"
    unit_of_measurement: "lqi"
    value_template: "{{ value_json.linkquality }}"
 
binary_sensor:
  - platform: "mqtt"
    name: Topení koupelna - baterie
    state_topic: "zigbee2mqtt/Topení koupelna"
    availability_topic: "zigbee2mqtt/bridge/state"
    payload_on: true
    payload_off: false
    value_template: "{{ value_json.battery_low}}"
    device_class: "battery"         
    
lock:
  - platform: "mqtt"
    name: Topení koupelna - child lock
    availability_topic: "zigbee2mqtt/bridge/state"
    state_topic: "zigbee2mqtt/Topení koupelna"
    command_topic: "zigbee2mqtt/Topení koupelna/set"
    payload_lock: "LOCK"
    payload_unlock: "UNLOCK"
    state_locked: "LOCKED"
    state_unlocked: "UNLOCKED"
    value_template: "{{ value_json.child_lock }}"
  
climate:
  - platform: "mqtt"
    name: Topení koupelna
    availability_topic: "zigbee2mqtt/bridge/state"
    temperature_unit: "C"
    min_temp: "5"
    max_temp: "35"
    mode_state_topic: "zigbee2mqtt/Topení koupelna"
    mode_state_template: "{{ value_json.system_mode }}"
    mode_command_topic: "zigbee2mqtt/Topení koupelna/set"
    current_temperature_topic: "zigbee2mqtt/Topení koupelna"
    current_temperature_template: "{{ value_json.local_temperature }}"
    temp_step: 0.5
    action_topic: "zigbee2mqtt/Topení koupelna/set"
    action_template: "{% set values = {'idle':'off','heat':'heating','cool':'cooling','fan only':'fan'} %}{{ values[value_json.running_state] }}"
    modes: 
      - "off"
      - "heat"
      - "auto"
    hold_modes: 
      - "away"
    hold_command_topic: "zigbee2mqtt/Topení koupelna/set"
    hold_state_template: "{{ value_json.preset }}"
    hold_state_topic: "zigbee2mqtt/Topení koupelna"
    temperature_state_topic: "zigbee2mqtt/Topení koupelna"
    temperature_state_template: "{{ value_json.current_heating_setpoint }}"
    temperature_command_topic: "zigbee2mqtt/Topení koupelna/set"    

Now I can read all data from Immax 07703L radiator valve. But when I am trying to send data (change child lock or heating setpoint), I get “No converter available” in Zigbee2mqtt log. I am using converters same as in ETOP HT-10, which were already created, with the right payload parametres configuration of each entitiy in configuration.yaml. Any idea what could be the problem?

Zigbee2MQTT:debug 2020-10-11 22:08:29: Received Zigbee message from 'Topení koupelna', type 'commandSetDataResponse', cluster 'manuSpecificTuyaDimmer', data '{"data":{"data":[0,0,0,250],"type":"Buffer"},"dp":515,"fn":0,"status":0,"transid":120}' from endpoint 1 with groupID 0
Zigbee2MQTT:info  2020-10-11 22:08:30: MQTT publish: topic 'zigbee2mqtt/Topení koupelna', payload '{"away_mode":"OFF","battery_low":"OFF","child_lock":"UNLOCKED","current_heating_setpoint":"35.0","device_offline":"OFF","external_sensor_error":"OFF","high_temperature":"OFF","internal_sensor_error":"OFF","linkquality":42,"local_temperature":"25.0","low_temperature":"OFF","preset":"none","running_state":"idle","system_mode":"off","weekly_schedule":{"1":{"dayofweek":1,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1050},{"heatSetpoint":"20.0","transitionTime":1320}]},"2":{"dayofweek":2,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1050},{"heatSetpoint":"20.0","transitionTime":1320}]},"3":{"dayofweek":3,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1050},{"heatSetpoint":"20.0","transitionTime":1320}]},"4":{"dayofweek":4,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1050},{"heatSetpoint":"20.0","transitionTime":1320}]},"5":{"dayofweek":5,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1050},{"heatSetpoint":"20.0","transitionTime":1320}]},"6":{"dayofweek":6,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1140},{"heatSetpoint":"20.0","transitionTime":1320}]},"7":{"dayofweek":7,"mode":1,"numoftrans":4,"transitions":[{"heatSetpoint":"20.0","transitionTime":420},{"heatSetpoint":"20.0","transitionTime":720},{"heatSetpoint":"22.5","transitionTime":1140},{"heatSetpoint":"20.0","transitionTime":1320}]}}}'
Zigbee2MQTT:debug 2020-10-11 22:09:46: Received MQTT message on 'zigbee2mqtt/Topení koupelna/set' with data 'LOCK'
Zigbee2MQTT:error 2020-10-11 22:09:46: No converter available for 'state' (LOCK)

Did you do step 5 here https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html

I have HassOS installation, so I used link https://github.com/danielwelch/hassio-zigbee2mqtt#adding-support-for-new-devices at the bottom of that manual. Anyhow, I tried to find homeassistant.js and I wasn’t able to. I cannot find folder “lib” in my HassOS, I tried to access via File folder and Samba Share. Is this folder exist in HassOS, is it somehow protected or is it custom folder and I have to create it?

I am too tired tonight to work that out, it is more complex with the addon isn’t it :hot_face:

There are two parts to getting a new device supported:

  • Find the correct way to change the files required for testing an unsupported device
  • Actually writing the correct code and converters to make it work

As you are using the official add-on, unfortunately the only working approach is using the hack with devices.js which is sometimes complicated to get right if versions change and you can lose your changes, but it’s doable and the docs should give you the right information on how to use this.

Unfortunately the better way is using external_converters but that has a bug in 1.15.0. There is a fork that fixes this bug in version 1.15.0-3 if you want to test that out.

The approach with devices.js will probably get dropped in future versions. Using external_converters is also the approach that the official documentation now supports.


Now for actually writing converters and correct properties I’m not that experienced, but you should be able to get support through using the github issues. The problem with Home Assistant discovery is probably an incomplete setup for the new device.

2 Likes

Hey Lukáš,

thanks for the work you did on the device definition. I stumbled upon the same problem as you and I believe you can find a workaround here: Need help with value_template for MQTT HVAC before the mqtt climate platform supports temperature_command_template. I believe it will work, but can’t test it now, because I’m stuck on another problem: https://github.com/Koenkk/zigbee2mqtt/issues/2500. Hope you will avoid it :slight_smile:

Here is the automation definition I use:

- alias: 'setpoint converter'
  trigger:
    platform: mqtt
    topic: home/0xec1bbdfffee4d5da/setpoint #<-- this can be any topic and you should set the temperature_command_topic in your entity config to the same value
  action:
    service: mqtt.publish
    data_template:
      topic: zigbee2mqtt/0xec1bbdfffee4d5da/set # <-- change this for your own topic
      payload: '{"current_heating_setpoint": {{trigger.payload}}}'

Cheers!

Hi Ladislav,
thanks a lot! It finally works, when I used this automation.

One more thing :grin: - the Immax 07703L TRV is now currently officialy supported in zigbee2mqtt version 1.16.0 probably thanks to your contribution. :wink: I tested it and it works like a charm :slight_smile:. I even have it registered as a regular Home Assistant device now thanks to MQTT device discovery. No need for this workaround anymore as it just works :).

So once again, thanks!

1 Like

Lukáš, I found one more interesting thing regarding the ‘MAC transaction expired’ (240) error, if you or anybody else encounter it using the Immax 07703L TRV. When the TRV is connected directly to my Zigbee coordinator CC2531 it doesn’t work and throws this error. When it’s connected through another device (Sonoff BASICZBR3 in my case) it works. :slight_smile: Magic… L.

Hi Lukas, thank you for your excellent work on this integration. I have bought 3 TRVs and there are 2 more on the way. Everything works like a charm … but from time to time there are artificial spikes (approx. 3 C) in the local_temperature to what seems to be a fixed temperature (25.2 C). Any ideea? Do you think it would be possible to use some other temperature sensor to push the local temperature to the TRV?

Just to be clear you seem to be saying that it isn’t possible to use external converters with the official add-on, is that right?

Hello

After reading this reply I have bought same devices, but for me it does not work .I have the same problem as the original reporter - devices is added but no entities.
Do you maybe know how to check the version of zigbee2mqtt I am running?

I already opened other thread for this problem, but no luck for now Mqtt - How to use device type specific configuration

If you are running the addon it is right at the top of the supervisor addon page.