[SOLVED] XIAOMI IO with Aqara LLKZMK11LM Two-way Control Module Wireless Relay

Hello, forgive me if I am asking a silly question , I am still a newbee…
Unfortunately the 2 relay isn’t included in the Xiaomi Smarthome binding…that would be awesome.
I am trying to add the Xiaomi 2 relay to the Xiaomi IO Binding, I can discover a Xiaomi device and another that has the name of the gateway behind. Once I enter the token, it becomes green and online.
But how do I make it work? Don’t I need to send a command, and how should I do this…
Please help, it would be really great to get this working. I only need switch L1 and L2 on and off…don’t care too much about the Power measurement. THANKS A BUNCH FOR HELP!

Click the blue circle under Actions or Power On/Off then you will have the option to add the channel/item

Hello H102! I did that and added a new switch item. However it doesn’t do anything… as this is an unspported device, is there anyting else I need to do? Also how does it know which is channel 1 or 2?

Thanks for any furhter advice!

Arto

Did you click on the “Linked Items +” to see if there is another channel that can be linked?

Yes I did…it shows nothing… it gives me only the option to “link” channel and “item”.
Since it is an unsupported device, I believe one needs to define the command parameters but I dont know how that would work, or what the command needs to be… It is a zigbee device. When I google the forum, I could find that someone could get it to work with MQTT and Zigbee USB stick, but I dont own one and it works well through the Xiaomi hub / app… I replaced it from a not reliable z-Wave Fibraro one as the distance to RPI is apporx 10m it was not realiable with zwave.

Looking at github there is an open issue. See https://github.com/openhab/openhab2-addons/issues/5662

Looks like you may to get a Zigbee USB or try NodeRed. Do you have an Echo device with zigbee e.g. Amazon Echo Plus?

BTW I use zigbee2mqtt and have no issues and you can get the C2531 USB stick for cheap.

See this link for what you will need to get started.

Also it support your device.

Hi… Nope - I only have the Xiaomi Gateway. No Echo device either… Hmm, that’s a real shame that this dual relay with power measurement AND Interlock mode (only either can be activated) isn’t supported by the smarthome binding. I could see this piece being really useful to automate sun shaders , etc… I am using it to switch things when there is excess Solar power…

With an open issue on git these features may be included in the near future.:crossed_fingers:

Have a look at Shelly devices.:wink: https://shelly.cloud/ Just click on Products tab to see all that is available. I use several of these and there my favorite thus far.

cool- those look like great value as well! OK… so I need to have zigbee to mqtt… Well likely I will then order the parts, and while I do this I will likely upgrade my RPI3 to nextgen… but I will get rid of my Z wave- to few devices and to big of a distance… Someone needs a RAZberry board , a Firbraro plug and a dual relay? :slight_smile:

If your using Shelly devices there is nothing extra needed.

If you order the CC2531 USB stick and set it up with OH you can still use the devices you have.

Hello again,

so… I now have set up the CC2531 and Mosquitto on the RP4. I have never worked with Mqtt Binding or mqtt… so I am a bit confused to what to do next - and HOW I can get an item updated or the channels switched… I guess I need things and items - can someone please help a me- I am not a code guru…at least it seems talking to the RP4 by mqtt. THANKS for support! :smiley:
A

info  2019-12-30 20:19:35: Device '0x00158d00045c2568' joined
info  2019-12-30 20:19:35: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"device_connected","message":{"friendly_name":"0x00158d00045c2568"}}'
info  2019-12-30 20:19:35: Starting interview of '0x00158d00045c2568'
info  2019-12-30 20:19:35: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"interview_started","meta":{"friendly_name":"0x00158d00045c2568"}}'
info  2019-12-30 20:19:37: Successfully interviewed '0x00158d00045c2568', device has successfully been paired
info  2019-12-30 20:19:37: Device '0x00158d00045c2568' is supported, identified as: Xiaomi Aqara wireless relay controller (LLKZMK11LM)
info  2019-12-30 20:19:37: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"pairing","message":"interview_successful","meta":{"friendly_name":"0x00158d00045c2568","model":"L$
info  2019-12-30 20:20:00: MQTT publish: topic 'zigbee2mqtt/0x00158d00045c2568', payload '{"state_l2":"OFF","linkquality":131}'
info  2019-12-30 20:20:03: MQTT publish: topic 'zigbee2mqtt/0x00158d00045c2568', payload '{"state_l2":"ON","linkquality":128}'
warn  2019-12-30 20:20:07: No converter available for 'LLKZMK11LM' with cluster 'genTime' and type 'read' and data '["time"]'
warn  2019-12-30 20:21:07: No converter available for 'LLKZMK11LM' with cluster 'genTime' and type 'read' and data '["time"]'
warn  2019-12-30 20:22:07: No converter available for 'LLKZMK11LM' with cluster 'genTime' and type 'read' and data '["time"]'
warn  2019-12-30 20:23:07: No converter available for 'LLKZMK11LM' with cluster 'genTime' and type 'read' and data '["time"]'
warn  2019-12-30 20:24:07: No converter available for 'LLKZMK11LM' with cluster 'genTime' and type 'read' and data '["time"]'
info  2019-12-30 20:25:01: MQTT publish: topic 'zigbee2mqtt/0x00158d00045c2568', payload '{"state_l2":"ON","linkquality":131,"power":1.35,"consumption":0.05,"temperature":29}'

I found follwoinf, but dont know how that translates to openhab

Blockquote
switch:

  • platform: “mqtt”
    state_topic: “zigbee2mqtt/<FRIENDLY_NAME>”
    availability_topic: “zigbee2mqtt/bridge/state”
    payload_off: “OFF”
    payload_on: “ON”
    value_template: “{{ value_json.state_l1 }}”
    command_topic: “zigbee2mqtt/<FRIENDLY_NAME>/l1/set”

switch:

  • platform: “mqtt”
    state_topic: “zigbee2mqtt/<FRIENDLY_NAME>”
    availability_topic: “zigbee2mqtt/bridge/state”
    payload_off: “OFF”
    payload_on: “ON”
    value_template: “{{ value_json.state_l2 }}”
    command_topic: “zigbee2mqtt/<FRIENDLY_NAME>/l2/set”

sensor:

  • platform: “mqtt”
    state_topic: “zigbee2mqtt/<FRIENDLY_NAME>”
    availability_topic: “zigbee2mqtt/bridge/state”
    unit_of_measurement: “-”
    value_template: “{{ value_json.linkquality }}”

Use PaperUI to create your mqtt things and files for items. Note you will need to have a generic mqqt thing for each device. After you have the mqtt thing it will show you the channels and the correct syntax to use in our items file.

Here is a link that has a video. First time setup of MQTT [solved]

Here’s a post with some item file examples for mqtt. It also has files for things so make sure to look at each example so not to get confused. Need help to migrate to the mqtt binding v2 in openhab 2.4

Hello! It is now working! I found a great manual with configuring the mqtt message for the dual relay here :

It can be configured as mihome:ctrl_ln2. I can switch on and off. No other features like power usage.