Guide - How to Use the ZS06 or UFO-R11 Zigbee IR controllers with SmartIR

I recently bought the Moes UFO-R11 controller to control devices using infrared (IR).

I wanted to use the SmartIR integration to create entities for my air conditioner and fan, but it took me quite a while to get everything working properly.

The information available online is scattered and often unclear, so I’ve prepared this unified, easy-to-follow guide that explains exactly how to get it all running.


Step 1: Connect to Zigbee2MQTT and then to Home Assistant

To pair the device, simply hold the button for about 5 seconds until the LED indicator starts flashing .

I’m using Zigbee2MQTT, so after pairing, it should look something like this:

Let’s make sure the controller works:

  • Click the ON button on the learn_ir_code entity.→ The LED on the device should light up.
  • Point your remote at the device and press the button you want to clone once .
  • The code will appear in the learned_ir_code field.
  • Copy that code into the ir_code_to_send field to test it (click away to trigger the send).

If everything works — great! You’re ready to create the entity you want to control using SmartIR.


Step 2: Choose or Create an IR Code File

We have two options:

  1. Use an existing community-scanned code file from SmartIR.
  2. Create our own code file.

In this tutorial we will use an existing community-scanned code file.
Go to the device platform list here:
:point_right: GitHub - smartHomeHub/SmartIR: Home Assistant integration to manage climate systems, TVs, fans and lights using IR/RF controllers. Compatible with Broadlink, Xiaomi, MQTT, LOOKin and ESPHome

Search for your device’s code file.

In this example, I’ll create an air conditioner (Climate platform) entity for my Tadiran Alpha Series .

The corresponding code file for this AC is 1343.

Note that this is a Base64-encoded code file designed for Broadlink controllers , but that’s fine — we can convert it to MQTT Raw format , which our device understands.

You won’t find MQTT controller code files in SmartIR, because existing Broadlink files can be converted.


Step 3: Convert Broadlink Codes to Row MQTT Format

After finding the correct file for your device, download it to your computer.

Then copy the following Python script from here:

:point_right: Convert SmartIR Broadlink commands to Tuya · GitHub

Now open a Python editor (I used PyCharm) and paste in the script you copied.

Place the AC’s JSON code file (from the previous step) in the same folder and run the following command in the terminal:

python3 broadlink_to_tuya.py 1343.json > 9990.json
  • 1343.json → the original Broadlink IR code file.
  • 9990.json → the new converted file that will be generated in the same directory.

This new file is equivalent to the original but contains codes in a format compatible with your controller .

You can test one of the converted codes by pasting it into the ir_code_to_send field in your controller to confirm it works.


Step 4: Create the SmartIR Entity in Home Assistant

If you haven’t installed SmartIR yet, do so now:

:point_right: GitHub - smartHomeHub/SmartIR: Home Assistant integration to manage climate systems, TVs, fans and lights using IR/RF controllers. Compatible with Broadlink, Xiaomi, MQTT, LOOKin and ESPHome

Next, upload the converted file to the SmartIR codes directory:

/homeassistant/custom_components/smartir/codes/climate/

Place the 9990.json file you generated earlier there.

Now, let’s create the air conditioner entity itself:

Open /homeassistant/configuration.yaml and add the following configuration:

smartir:

climate:
  - platform: smartir
    name: Living Room AC IR
    unique_id: living_room_ac_ir
    device_code: 9990
    controller_data: zigbee2mqtt/FRIENDLY_NAME/set/ir_code_to_send

Replace FRIENDLY_NAME with the friendly name you gave your controller in Zigbee2MQTT.
For example, mine is: zigbee2mqtt/Living Room IR Remote/set/ir_code_to_send

:warning: Note: Use only the numeric part of the file name (9990), without the .json extension.


Step 5: Restart Home Assistant

Restart Home Assistant — and that’s it!

Your new SmartIR entity is ready and fully functional :tada:

1 Like

Thanks for putting together this guide, trying to setup a UFO-R11 currently and came across this one as one of the most well put together guides. I am still trying to understand something at a very basic level, so please excuse the question, but wondering if you can help from your experience/research. What is the benefit of using the SmartIR integration over and above just using the MQTT integration to learn the codes and a HA script to send said codes?

My use case is an on/off operation of IR controlled candles, for which there is not an existing SmartIR code file. So perhaps SmartIR makes far more sense for controlling AC units. One of the big issues I’m facing with my devices to be controlled is that they seem to use rolling codes even for simple on/off, no idea why a battery powered candle needs rolling codes…

1 Like

I’m glad the guide helped you :blush:
For simple devices like IR Light bulbs, I just use plain MQTT in a Light Template in Home Assistant, it works perfectly for on/off without SmartIR and still creates the entity.
SmartIR is nice for devices where you want proper state management and full entity support.

Regarding rolling codes - I haven’t encountered such a case yet because I don’t have a device that uses rolling codes, so I can’t help with that.
Maybe someone from the community can answer that.

Thanks again. Curiously; after further research and testing, I found that creating a script with a MQTT Publish action to work well, whereas in the visual editor the intuitive option is to first select the IR remote as a device type and then the available action is “set value for code to send”. Also curiously; despite the remotes creating a unique code each time, using the learn IR code in the MQTT add-on, the devices respond to the same single code being sent every time from the script, so rolling code seems to not be such an issue.

Excuse the slightly off topic - just sharing thoughts in case it is useful for the community

1 Like