Broadlinkac2mqtt - Control your broadlink-based air conditioner with Home Assistant

I see there is Added support of Home Assistant BIRTH AND LAST WILL MESSAGES. Does that mean I can check the current state the air conditioning is in?

My situation is this:
I do have the broadlink RM4 Pro switching my aircon on and off through IR.
When I leave the house it has to switch off the aircon.
I want to be able to check if it is really switched off, so the aircon is not running for days or weeks when I’m on holiday.
Another thing is when the aircon is not running and the Broadlink will send the on/off command it will turn on instead of off.

Is this last will message a way to do this?
Is it possible anyway for the aircon to report back over IR?

Hello!

IR has no feedback. The signal is sent in one direction only

Yes, I thought so. I’m wondering how do those AC remotes get their information on the display. I’ve seen information on current temp, goal temp, fan speed, etc. Does that work with RF?

I’ve made a few changes to the addon. Can anyone check if the program is running? I don’t have a raspberry at the moment to test. it is necessary to check the dev branch

I’m just trying to integrate my AUX air conditioner, my HA runs on a Raspberry Pi 3 B+. I would say the addon is running but I cannot authenticate with the air conditioner.

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
s6-rc: info: service legacy-services successfully started
{"time":"2024-04-11T20:40:15.67812641Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/webClient.(*webClient).SendCommand","file":"/github/workspace/app/webClient/client.go","line":43},"msg":"Failed to read the response","err":"read udp 172.30.33.3:38986->192.168.1.162:80: i/o timeout"}
{"time":"2024-04-11T20:40:15.678815573Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).SendCommand","file":"/github/workspace/app/service/service.go","line":720},"msg":"failed to send a command","err":"read udp 172.30.33.3:38986->192.168.1.162:80: i/o timeout","device":"<macAdress>","input":{"Payload":"WqWqVVqlqlUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADu7wAAKk5lAH9b7Auu06w6AAAAAKHDAABFNFLn+S7alYNEkwg175pt+2ktw3C5BEOsXNY/u1Ot+giBTKf4z0FxADKOVww7hslNBXCESaOJ4prhBFQ2oFvd3ALBYa8TJeh+GbD30c4GjQ==","Ip":"192.168.1.162","Port":80}}
{"time":"2024-04-11T20:40:15.680329992Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).AuthDevice","file":"/github/workspace/app/service/service.go","line":137},"msg":"failed to send command","err":"read udp 172.30.33.3:38986->192.168.1.162:80: i/o timeout","input":{"Mac":"<macAdress>"}}
{"time":"2024-04-11T20:40:15.681011186Z","level":"ERROR","source":{"function":"main.(*App).Run.func1","file":"/github/workspace/main.go","line":162},"msg":"failed to Auth device <macAdress>. Reconnect in 3 seconds...","err":"read udp 172.30.33.3:38986->192.168.1.162:80: i/o timeout"}

2024-04-22_16-46-55

This is all im getting when trying to start the dev version.

Hello,
I’ve discovered that newer Broadlink models primarily communicate through a cloud API, marking a shift away from the local MQTT methods we’re accustomed to. During my tests using the AC Freedom app and PCAPdroid app, I was able to control the air conditioner by sending commands in JSON format. For example:

With commands like "act": "set" and "act": "get", you can adjust the temperature or retrieve information. However, a downside is that if Broadlink updates their API or if the cloud service goes down, this method won’t work anymore.

Has anyone else experimented with this API?

4 Likes

Hey thanks for this but I have some questions. Currently have the Broadlink integration in my Home assistant but have been controlling via scripts.

I have a LG, Panasonic, Fujitsu, Mitsubishi and Diakin and accordingly have a RM pro, and 4 RM mini’s. So its been a pain setting it up since add scripts have to be done manually. I added all AC’s to Broadlink app but need control in HA.

What I am asking is if Broadlinkac2mqtt has support for all these and if all those can be controlled within home assistant? Sorry new to it so trying to understand how it works etc.

Ok on reading the info again I am thinking you are referring to specific chipset based Air cons. Sorry the confusion is due to same name.

@Artem_Vladimirov just wanted to say it works!
It works with my AUX Freedom

I use HA Green (not raspberry not Linux etc)
I used repository option.

  1. Add AC to AC freedom app
  2. Get mac and IP from router admin (edit mac to proper format)
  3. Edit config with the above data

Done
Device is there, Ican control everything (the Celcus and farenheit is wrong, but I’ll see what’s the problem later)

hope this helps

Dears,
I’m a bit lost. I’m kind of new to this. I made all the requested steps and no matter how I change the configuration I don’t have my AirCon discovered.
This is the log:

{“time”:“2024-05-18T08:46:14.688169243Z”,“level”:“ERROR”,“source”:{“function”:“github.com/ArtemVladimirov/broadlinkac2mqtt/app/webClient.(*webClient).SendCommand",“file”:“/github/workspace/app/webClient/client.go”,“line”:43},“msg”:"Failed to read the response”,“err”:“read udp 172.30.33.3:37855->192.168.1.56:80: i/o timeout”}
{“time”:“2024-05-18T08:46:14.688415043Z”,“level”:“ERROR”,“source”:{“function”:“github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).SendCommand",“file”:“/github/workspace/app/service/service.go”,“line”:720},“msg”:"failed to send a command”,“err”:“read udp 172.30.33.3:37855->192.168.1.56:80: i/o timeout”,“device”:“e81656309584”,“input”:{“Payload”:“WqWqVVqlqlUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADF7wAAKk5lAMas6BZWMJWEAAAAAKHDAABFNFLn+S7alYNEkwg175pt+2ktw3C5BEOsXNY/u1Ot+giBTKf4z0FxADKOVww7hslNBXCESaOJ4prhBFQ2oFvd3ALBYa8TJeh+GbD30c4GjQ==”,“Ip”:“192.168.1.56”,“Port”:80}}
{“time”:“2024-05-18T08:46:14.68856479Z”,“level”:“ERROR”,“source”:{“function”:“github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).AuthDevice",“file”:“/github/workspace/app/service/service.go”,“line”:137},“msg”:"failed to send command”,“err”:“read udp 172.30.33.3:37855->192.168.1.56:80: i/o timeout”,“input”:{“Mac”:“e81656309584”}}
{“time”:“2024-05-18T08:46:14.688623596Z”,“level”:“ERROR”,“source”:{“function”:“main.(*App).Run.func1”,“file”:“/github/workspace/main.go”,“line”:162},“msg”:“failed to Auth device e81656309584. Reconnect in 3 seconds…”,“err”:“read udp 172.30.33.3:37855->192.168.1.56:80: i/o timeout”}

“”"

Someone can tell me what am I do wrong?
Thanks,
Nuno

Would you mind sharing exactly how you accomplished it? I’ve just moved in to an apartment with two such units and I’d love to be able to control them with HA.

Or perhaps there are other solutions?

Same here. “failed to Auth device” is all I get. These are relatively newer models unfortunately. Maybe there is a network card for these that is easy to swap with something compatible?

It doesn’t. It stops after a short while with no errors in the log. Non-dev version works fine.

Hi @Artem_Vladimirov.
I can’t figure out how to run the integration. It throws the following errors

{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).SendCommand","file":"/app/broadlinkac2mqtt/app/service/service.go","line":720},"msg":"failed to send a command","err":"read udp 172.30.33.5:44812->192.168.8.172:80: i/o timeout","device":"e816565e788f","input":{"Payload":"WqWqVVqlqlUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAR8AAAKk5lAM7U6BZWXniPAAAAAKHDAABFNFLn+S7alYNEkwg175pt+2ktw3C5BEOsXNY/u1Ot+giBTKf4z0FxADKOVww7hslNBXCESaOJ4prhBFQ2oFvd3ALBYa8TJeh+GbD30c4GjQ==","Ip":"192.168.8.172","Port":80}}
{"time":"2024-05-28T06:29:25.371553085Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).AuthDevice","file":"/app/broadlinkac2mqtt/app/service/service.go","line":137},"msg":"failed to send command","err":"read udp 172.30.33.5:44812->192.168.8.172:80: i/o timeout","input":{"Mac":"e816565e788f"}}
{"time":"2024-05-28T06:29:25.37161692Z","level":"ERROR","source":{"function":"main.(*App).Run.func1","file":"/app/broadlinkac2mqtt/main.go","line":162},"msg":"failed to Auth device e816565e788f. Reconnect in 3 seconds...","err":"read udp 172.30.33.5:44812->192.168.8.172:80: i/o timeout"}
{"time":"2024-05-28T06:29:25.371967725Z","level":"ERROR","source":{"function":"main.(*App).Run.func1","file":"/app/broadlinkac2mqtt/main.go","line":162},"msg":"failed to Auth device e816565e975c. Reconnect in 3 seconds...","err":"read udp 172.30.33.5:43794->192.168.8.205:80: i/o timeout"}
{"time":"2024-05-28T06:29:25.370794956Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/webClient.(*webClient).SendCommand","file":"/app/broadlinkac2mqtt/app/webClient/client.go","line":43},"msg":"Failed to read the response","err":"read udp 172.30.33.5:41947->192.168.8.29:80: i/o timeout"}
{"time":"2024-05-28T06:29:25.371229207Z","level":"ERROR","source":{"function":"main.(*App).Run.func1","file":"/app/broadlinkac2mqtt/main.go","line":162},"msg":"failed to Auth device e816565e7bda. Reconnect in 3 seconds...","err":"read udp 172.30.33.5:54279->192.168.8.247:80: i/o timeout"}
{"time":"2024-05-28T06:29:25.372162489Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).SendCommand","file":"/app/broadlinkac2mqtt/app/service/service.go","line":720},"msg":"failed to send a command","err":"read udp 172.30.33.5:41947->192.168.8.29:80: i/o timeout","device":"e816565e6329","input":{"Payload":"WqWqVVqlqlUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABL7wAAKk5lAK+o6BZWXmMpAAAAAKHDAABFNFLn+S7alYNEkwg175pt+2ktw3C5BEOsXNY/u1Ot+giBTKf4z0FxADKOVww7hslNBXCESaOJ4prhBFQ2oFvd3ALBYa8TJeh+GbD30c4GjQ==","Ip":"192.168.8.29","Port":80}}
{"time":"2024-05-28T06:29:25.37226564Z","level":"ERROR","source":{"function":"github.com/ArtemVladimirov/broadlinkac2mqtt/app/service.(*service).AuthDevice","file":"/app/broadlinkac2mqtt/app/service/service.go","line":137},"msg":"failed to send command","err":"read udp 172.30.33.5:41947->192.168.8.29:80: i/o timeout","input":{"Mac":"e816565e6329"}}
{"time":"2024-05-28T06:29:25.372327604Z","level":"ERROR","source":{"function":"main.(*App).Run.func1","file":"/app/broadlinkac2mqtt/main.go","line":162},"msg":"failed to Auth device e816565e6329. Reconnect in 3 seconds...","err":"read udp 172.30.33.5:41947->192.168.8.29:80: i/o timeout"}

Could you please have a look?
Maybe something was changed on the app side?

Thanks,
Ilya

Strange thing. I have an access to my AUX Airco via AC Freedom APP, but I cannot get access via Broadlinkac2mqtt. I have correct IP, correct MAC.

I have OFFLINE message, but as I mentioned above - AC is online and available via AC Freedom APP.

Subscribed topics:

  • aircon/a043b0f09c9d/availability/value

3 latest received messages

  • Received 18:50:24

    • QoS: 0
    • Payload: offline
  • Received 19:20:38

    • QoS: 0
    • Payload: offline
  • Received 19:25:49

    • QoS: 0
    • Payload: offline

Hello @Artem_Vladimirov,

I can confirm regular addon (not tried -dev) works on Vortex AC. I did not delete the device from AC Freedom app.

Many thanks

There is different between hass addon to the docker version ??

Hi
how does this work exactly?
I have five indoor devices with WiFi and would like to integrate them into HA.

I have now downloaded broadlinkac2mqtt and added an air conditioner in the king.

What has to happen now or what do I have to do so that I can now see this device in HA?

Where can I find logs about this?

FYI, for those people who are struggling with adding devices, and getting the “Checksum is incorrect” or “response is too short”. It might be caused by the AC Freedom app changing the encryption keys. Here’s how to fix it:

note that the wifi reset procedure might be different, here’s all the possibilities: https://auxsolutions.gr/wp-content/uploads/WiFi-manual.pdf

one downside of this is that we can’t use the AC Freedom app (it’s a bit crappy anyway ,lol)