Multiple broadlink RM3 devices = duplicated commands in configuration?

I’m a bit confused by the broadlink configuration documentation. I’m aiming to add two broadlink RM3 devices to Home Assistant. Maybe mine is a bit of an edge case, but I have the same model of TV and IR controllable heat pump both upstairs and down, where my two broadlinks will be located. So far, it looks like I’ll have to duplicate all the IR codes in the configuration for each switch. That’s doable, but it kind of sucks.

Alternatively, is it possible to configure a device in HA where its various actions are running command line utilities? I could integrate with an existing component I had to run IR commands on my broadlinks by using curl to hit its web interface.

I think you could make cunning use of include here, and map your ir codes in to an include file and use the same include file for both broadlinks.

Then what I think will happen is you’ll get like broadlink.volume_up and broadlink.volume_up_2 where 2 will be the second device.

I don’t know whether it will work, or how reliable it is that 2 will always be the second device if you rebooted, but that’s what I’d try first :+1:

I would use the custom climate and media broadlink component

You could configure your two RM3 an point one TV and one climate to one RM3 IP and the other tv and climate unite to the second RM3 IP.
In that way you only put your codes once and reuse them in both RM3 units
I guess it shoulwork.
I am using it with one RM3 and it works great.
I will add a second one and test by the end of the month!

Yes it will work with multiple devices.

By the way Vassilis, great work with those custom components, they work amazing!
I owe you a Beer, whenever you find yourself in the south of France!

I am have 2x RM3 and 1x RM Pro+. RM Pro+ work great with all IR and RF devices. I got one RM3 working but my other RM3 entitiy IDs are not recognized ny HA.

I restarted and try to refresh but entities are not getting added. All devices work with IHC and E-control app

Running HA ver 0.71 or latest

Much appreciate your help

My switches.YAML and Scripts.YAML attaches. I include the script in Groups and the call in front end

scripts.yaml (2.1 KB)
switches.yaml (17.1 KB)

1 Like

Same issue unable to see the entities of the second RM2. I can however see both the broadlink devices and send and receive commands from the Developer Tools >Services.

Hi anyone still having the issue with multiple broadlink devices?

I am going to buy another RM2 device for extending the RF range in other room/basement, but it seems having problem in this topic?

Thank you

I finally got around to using the broadlink component for HA, and I have a solution to reusing the same commands on multiple broadlink devices. I’ve defined a JSON file format like this:

  "device_name": {
    "command_1": "code here",
    "command_2": "code here"
  "another_device": {
    "some_command": "code"

This way you can define commands per the device that accepts them, and not per the device that broadcasts them.

First, I have my broadlinks defined like this:

  - platform: broadlink
    friendly_name: Broadlink (livingroom)
    host: '[IP address]'
    mac: '[MAC address]'

  - platform: broadlink
    friendly_name: Broadlink (recroom)
    host: '[IP address]'
    mac: '[MAC address]'

I have a command line sensor for which I define a json_attributes item for each IR-controllable device I have in the JSON. This file is rarely going to change, so I set it to refresh only once a day (86400 seconds). The state of the sensor is the time when it was last refreshed.

  - platform: command_line
    name: broadlink_commands
    command: 'cat /home/hass/config/packages/platforms/broadlink_commands.json'
    value_template: '{{ states("sensor.date_time") }}'
    scan_interval: 86400
      - device_name
      - another_device

And finally a script to allow me to specify readable calls to send IR commands:

      - service: broadlink.send
          host: >
            {%- set rooms = {
              'livingroom': '[IP address]',
              'recroom': '[IP address]'
            } -%}
            {{ rooms[room | lower] }}
          packet: >
            {{ state_attr('sensor.broadlink_commands', device)[command] }}

Called like this:

      - service: script.broadlink_send_command
          room: livingroom    <----  This is defined in the script above
          device: device_name <---- These values are referenced from the JSON file of commands
          command: command_1  <----