ESP Haier: Haier Air Conditioner + ESP Home + Wemos D1 mini

Little update, seem to all work i set “alternative swing” to true and vertical flap work but horizzontal not work…i can find a method to know why?
and i don’t understand i see all your github but how can i write yalm file to use your many config file?

thank’s

As far as I remember not all smartAir2 ACs support horizontal swing control over serial. But you can try this haier-esphome/docs/faq.rst at ab6789c2caf7f4d9df2ac1ca3147e7f9ba1937f1 · paveldn/haier-esphome · GitHub Change horizontal swing with remote and you should be able to see changes in status packet in serial protocol if it is supported.

If you asking how to write yaml for ESPhome in general - topic is too big to explain in couple of words. Of you asking about haier component you should start with ESPHome help first:

Hi @MiguelAngelLV
If I’m not wrong, there is now in esphome a component that automatically adds the haier controls : Haier Climate — ESPHome
What’s the difference with your own custum component ?
Thanks

The component of EspHome was created by @paveldn . My component is a “grand grand father” of the Esphome Haier.

Use the component from EspHome :stuck_out_tongue:

:slight_smile: thank you very much for the quick reply

I’m trying to control my Haier AC using a D1 Mini with this ESPHome config (using the haier-esphome custom component), but it’s not working properly.

The logs show this loop:

[D][haier.protocol:019]: Sending frame: type 61, data: 00 07
[D][haier.protocol:019]: Frame found: type 62, data: ...
[D][haier.protocol:019]: Sending frame: type 01, data: 4D 01
[I][haier.climate:096]: Answer timeout for command 01, phase SENDING_FIRST_STATUS_REQUEST

It seems like the AC responds to type 61, but not to the 01 command.

YAML (relevant parts):

uart:
  - id: ac_port
    baud_rate: 9600
    tx_pin: 1
    rx_pin: 3

external_components:
  - source: github://esphome/esphome@dev
    components: [ haier ]

packages:
  remote_package:
    url: https://github.com/paveldn/haier-esphome
    ref: master
    files:
      - .haier-smartair2-base.yaml

What I tried:

  • RX/TX wiring double-checked
  • Proper UART pins (TX=GPIO1, RX=GPIO3 on D1 Mini)
  • Different cables, confirmed AC is powered

Anyone know what might be wrong? Thanks in advance!

Hi @N0edL ,

You don’t need external component, you can remove it.

AC’s that use SmartAir2 protocol usually don’t answers to 61 command. Can you try to use hOn protocol?

ALso it would be useful if you can provide full log. Answer to 61 command should have information about your device (like protocol version and firmware version)

Hi, I have a question, please. I have older Haier ACs that use the USB wifi dongle (which is really a UART, according to my understanding). If I buy these: M5Stamp C3U Mate with Pin Headers | m5stack-store and reprogram them with esphome, will they work in the hOn app and be able to be voice controlled by Alexa for example? As hOn has Alexa integration. Sorry if this a noob question but I would apppreciate the help.

Answers to your questions: no and maybe. You can’t have both hOn and ESPHome at the same time, only one of them will work. If you are using ESPHome with Haier component it is still possible to have voice assistant control but you should do it with Home Assistant.

Also interested in this. Both of my GE window AC’s use the uart usb wifi module.

Would really love to disconnect these from the cloud and have HA control them locally.

@paveldn

WARNING Using climate.CLIMATE_SCHEMA is deprecated and will be removed in ESPHome 2025.11.0. Please use climate.climate_schema(...) instead. If you are seeing this, report an issue to the external_component author and ask them to update it. *.*_SCHEMA deprecations - ESPHome Developer Documentation. Component using this schema: haier

Does this effect something?

No, at least not till 2025.11.0 :smile: I will take a look. Anyway, I have plans to make some changes to the code. Will also check this.

Are we sure about this? Because I’ve updated to 2025.7.0 and got the following error instead of the climate control card.

Immediately downgraded from a backup and everything seems to work as before.

Your problem should be something related to Home Assistant. Maybe some bug introduced in 2025.7.0. If there would be problem with ESPhome you wouldn’t be able to compile your configuration.

Can confirm, latest ESPHOME update breaks the integration.

1/3 my AC is not updated yet and works OK. Two of them are now at ESPHOME 2025.7.2 and stopped working (Answer timeout for command 61).

Interestingly, my issue still persists, but doesn’t seem related to the ESPhome builder version at the moment. ESPhome firmware was built off ESPhome 2025.7.0, Home Assistant Core is at 2025.6.3 and everything works. As soon as I upgrade Homeassistant to 2025.7, the climate entity disappears. Tried all Homeassistant 2025.7.x versions to date. Esphome configuration is the default from the integration’s github. Now I’m hesitant to build new 2025.7.2 firmware images.
I’ll try to find time next week to upgrade Homeassistant and get debugging logs to see what the problem is.

@biuklija
I don’t think this issue is related to ESPhome it should be Home Assistant related. I can’t reproduce it in my setup. Should be something related to your case. I just used ESPhome 2025.7.2 everything fine.

@Alloc186
In your case looks like serial port is not working. Are you using something that is not related to Haier AC like BT proxy or some other havy component?

Hmm, maybe the problem is with esp32-s3-devkitc-1 board and new update…

My Atom S3U was working all the time as esp32-s3-devkitc-1…
After last esphome update (i think) i lost my AC in homeassistant.

This was my working config:

substitutions:
  name: esphome-web-18eac9
  friendly_name: Haier AC
  uart_id: ac_port

esphome:
  name: ${name}
  friendly_name: ${friendly_name}
  min_version: 2024.6.0
  name_add_mac_suffix: false
  platformio_options:
    board_build.flash_mode: dio
  project:
    name: esphome.web
    version: '1.0'

esp32:
  board: esp32-s3-devkitc-1
  framework:
    type: arduino

# Enable logging
logger:
  level: DEBUG

# Allow Over-The-Air updates
ota:
- platform: esphome

# Allow provisioning Wi-Fi via serial
#improv_serial:

wifi:  
  ssid: !secret wifi_ssid
  password: !secret wifi_password
  # Optional manual IP
  manual_ip:
    static_ip: 192.168.1.15
    gateway: 192.168.1.1
    subnet: 255.255.255.0
  # Set up a wifi access point
  ap:
    ssid: ${friendly_name} " admin"
    password: !secret ap_wifi_pass

# In combination with the `ap` this allows the user
# to provision wifi credentials to the device via WiFi AP.
captive_portal:

#dashboard_import:
#  package_import_url: github://esphome/firmware/esphome-web/esp32s3.yaml@main
#  import_full_config: true

# Sets up Bluetooth LE (Only on ESP32) to allow the user
# to provision wifi credentials to the device.
#esp32_improv:
#  authorizer: none

# To have a "next url" for improv serial
#web_server:

# Haier AC

uart:
  baud_rate: 9600
  tx_pin: 19
  rx_pin: 20
  id: ${uart_id}

api:
  services:
    - service: turn_on
      then:
      - climate.haier.power_on: haier_ac
    - service: turn_off
      then:
      - climate.haier.power_off: haier_ac

climate:
  - platform: haier
    id: haier_ac
    protocol: smartAir2
    name: Haier SmartAir2 Climate
    uart_id: ${uart_id}
    alternative_swing_control: true
    wifi_signal: true
    visual:
      min_temperature: 16 °C
      max_temperature: 30 °C
      temperature_step: 1 °C
    supported_modes:
      - 'OFF'
      - HEAT_COOL
      - COOL
      - HEAT
      - DRY
      - FAN_ONLY
    supported_swing_modes:
      - 'OFF'
      - VERTICAL
    #  - HORIZONTAL
    #  - BOTH
    supported_presets:
    #  - BOOST
    #  - COMFORT
    #  - AWAY

switch:
  - platform: template
    id: haier_ac_health_mode
    name: Haier SmartAir2 Climate health mode
    icon: mdi:leaf
    restore_mode: RESTORE_DEFAULT_OFF
    lambda: |-
      return id(haier_ac).get_health_mode();
    turn_on_action:
      climate.haier.health_on: haier_ac
    turn_off_action:
      climate.haier.health_off: haier_ac
  - platform: template
    id: haier_ac_display_switch
    name: Haier SmartAir2 Climate display
    icon: mdi:led-on
    entity_category: config
    restore_mode: RESTORE_DEFAULT_ON
    lambda: |-
      return id(haier_ac).get_display_state();
    turn_on_action:
      climate.haier.display_on: haier_ac
    turn_off_action:
      climate.haier.display_off: haier_ac

maybe to tray something like this?

esp32:
board: m5stack-atom-s3
framework:
type: arduino

EDIT:
This abowe is not solution for my problem.
I will try to downgrade Homeassistant core

I have esphome in docker and after i downgrade my docker container to esphome:2025.6.3 and after I update my board from that esphome version I can again control my AC.

My Homeassistant is:
* Installation method Home Assistant OS
* Core 2025.7.4
* Supervisor 2025.07.2
* Operating System 16.0
* Frontend 20250702.3