ESP8266 (ESP12F) IR HomeKit Controller Conversion to Home Assisant?


I bought a pre-built module image hosted at ImgBB — ImgBB which runs this Mixiaoxiao/ESP8266-IR-HOMEKIT: 原生HomeKit红外空调遥控 (

However the IR library seems outdated and cannot control my AC.

Then I flash it with this LouisLee985/Homekit-Air-Conditioner-Remote: Homekit ESP8266空调红外反馈遥控器 ( but still can’t get it work.

Now I’m wondering if there is a simpler way to just make it work with Home Assistant? Any directions would be welcome!


Edit: Diagram of the pre-built module

1 Like

Use a KY-22 IR receiver and learn the codes from the AC original remote if the original remote works on the same frequency range. Search the forum for IR blaster for ideas on how to use it.

Flash with tasmota-ir bin firmware.
Press buttons on the original remote and see if the ir commands get detected.
Then use with tasmota-irhvac (hacs)

Thanks! Will look it up.

FYI, I’ve tried a Tuya module and it had no problem controlling the AC, thought it would be easy.

But didn’t want to use Tuya cloud so I got a Broadlink, which had some other issues related to WiFi.

So I finally got a ESP-based module which is where I’m now.

Perhaps I should seriously look into ESPHome…


Thanks! Will look it up!

For the remote with tuya module, you can install libretiny (esphome)

Thanks! I got to here…

But I dunno how to configure it… since it’s a pre-built module, all the wires are already connected. According to the Wiki of the original firmware

IR send: IO14 (D5)
IR receive: IO12 (D6)
Wifi LED: IO2 (D2)
IR LED: IO13 (D7)
Button: IO0 (D3)

Here is a photo of the module:

Edit: Found the parameters points and got below messages from remote

00:00:19.620 RSL: RESULT = {"IrReceived":{"Protocol":"UNKNOWN","Bits":254,"Hash":"0xE6DD6E07","Repeat":0}}
00:00:21.518 RSL: RESULT = {"IrReceived":{"Protocol":"UNKNOWN","Bits":128,"Hash":"0x19037C2B","Repeat":0}}
00:00:23.445 RSL: RESULT = {"IrReceived":{"Protocol":"UNKNOWN","Bits":6,"Hash":"0x1C3129FD","Repeat":0}}
00:00:25.742 RSL: RESULT = {"IrReceived":{"Protocol":"UNKNOWN","Bits":230,"Hash":"0xC242607D","Repeat":0}}

Edit 2: I cannot find the model (RAS-E13CAK/RAC-E13CAK) at IRremoteESP8266/ at master · crankyoldgit/IRremoteESP8266 (, so I guess I need to make the module “learn” the IR codes myself, right?

Just to verify, you did flash the tasmota-ir bin firmware right? Not the regular tasmota.bin

And still getting unknown protocol?

1 Like

Yes, tasmota-ir, I even flashed the wrong version (ESP32) before flashing the right one (ESP8266).


Can you try with esphome and use the hitachi climate component?


# Example configuration entry
  pin: GPIO14
  carrier_duty_percent: 50%

  - platform: hitachi_ac344       # adjust to match your AC unit!
    name: "Living Room AC"

If hitachi_ac344 or hitachi_ac424 doesn’t work try the heatpumpir platform

  - platform: heatpumpir
    protocol: hitachi

Sure! But how do I get the bin file to flash? I’ve looked around but still don’t get how to do it…

you need to compile it with the esphome addon.
here’s a yaml example using your receiver & transmitter pins

  name: test-ir
  friendly_name: test-ir

  board: esp01_1m

# Enable logging

# Enable Home Assistant API


  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
    ssid: "Test-Ir Fallback Hotspot"
    password: !secret ap_password


  port: 80
  id: rcvr
    number: GPIO12
    inverted: true
      input: true
      pullup: true
  # high 55% tolerance is recommended for some remote control units
  tolerance: 55%

  pin: GPIO14
  carrier_duty_percent: 50%

  - platform: hitachi_ac344       # adjust to match your AC unit!
    name: "Hitachi AC"
1 Like

Thanks! I’ll give it a try after work~

For some reasons my HAOS has no addon, so I installed via

However it has problem connecting to my WiFi (which worked under tasmota)

So I again have to give up for now.

Thanks a lot!

Sounds like you need to install hass supervised for addons/hacs/etc

1 Like