Midea branded AC’s with ESPhome (no cloud)

Well it appears some units need it, and some do not. I thought @Ice_Juice got his Wemos working without, but @vilord 's units did not respond to commands without a level shifter.

I currently run all my AC’s on ESP-01’s but I have some level shifters laying around to build two Wemos based dongles.

Reading your name I assume you are Dutch like me so sending you a link to a Dutch site won’t be a problem, I have these: https://www.bitsandparts.nl/Logic-Level-converter-shifter-I2C-5-3V-p1107480?gclid=CjwKCAiAhbeCBhBcEiwAkv2cY0_TNgwzuxXaqkmLt-kd9jMap1ym1iLVBXHYMvAB_OS6QxACF5eY1xoCl9UQAvD_BwE

I got the same thing, TX only in the logs until I used a level shifter to bring the 3.3v rx/tx up to 5v

just order them, did you connect via the usb port then ? wen you installed the shifter ?

indeed i aim ^^ just order them ^^

Yes to the faux-usb port

Just wanted to drop in and say another happy customer here…just got my level shifter and USB terminal adapter installed and everything appears to be working flawlessly.

1 Like

So I’ve been very interested in controlling these mini-splits for years. I have three of them in my home and have been successful in reverse engineering the IR commands used to control them. I’ve been using IR for a while but realized some time back that these devices have also have a serial bus built in that’s it used for comms and control. Each of the inside head units normally have a XYE bus that is used to communicate by RS-485. I tried some time back to reverse engineer that protocol but was never successful. After some research over the last few days I found someone who has, in fact, figured out the protocol. It’s here.

Curious if the folks who masterminded this awesome solution would be willing to have a look and consider integrating this as well?

1 Like

If you want to dive deeper into these things and talk to the developers (and a lot of interested people), please join the Telegram group, setup by @mac_zhou, that you can find here. Click here to join

1 Like

Did anybody try another chip or board for the dongle? I’m getting slightly annoyed by the fact, that I can’t update my ESP-01 via OTA (like @aceindy).

In theory it should work with a NodeMCU (ESP8266 or ESP32) and a voltage devider or a logic level shifter, shouldn’t it?

Yes it does. Wemos/Nodemcu with a level shifter does the job

1 Like

Thanks, I didn’t even think about the D1 :astonished: Not that it had been mentioned multiple times in this thread (eg. from you)… :nerd_face:

Hi there,

I have tryed the way @Ice_Juice did with a wemo d1 mini via USB but it doesn’t seem to compile.

INFO Reading configuration /config/esphome/airc.yaml...
Failed config

midea_ac: [source /config/esphome/airco.yaml:33]
  
  Component midea_ac cannot be loaded via YAML (no CONFIG_SCHEMA).
  name: Airco zolder
  beeper: True

Is there any possibility to get trough compiling?

thanks!

Normally this means you’re doing something wrong, either it is not the correct ESPHome version, or, if you use the dev version from ESPHome, you’re not using the correct syntax in your *.yaml.

Post the code of the ESPHome *.yaml file. My bet is on climate vs midea_ac. :slight_smile:

@Speezle
It seems the esphome config has changed recently…
so there is a difference when using dudanov’s repository or the office esphome repository.
Please change

midea_ac:
  name: "Midea AC"
  beeper: true

into

climate:
  - platform: midea_ac
    name: "Midea AC"
    beeper: true

I have adjust the original config in 1st topic also :wink:

2 Likes

Thanks that indeed worked for me!

also made meself a rather nice usb dongle for my airco unit

I did need the logic level shifter without it wouldn’t work.
So far it’s working great!

2 Likes

I also made the dongle as @Speezle shared above, thank you for the idea. I noticed that Midea A/C is now fully integrated into ESPHome 1.17.0! Got it working, but still trying to figure out which buttons do what on the Thermostat card.

1 Like

Hello all, I’ve been lurking over this thread and reading with great interest…

I recently install a Midea U-shaped AC unit (model MAW12V1QWT, link on amazon: https://www.amazon.com/gp/product/B0867GMW9X/?th=1) that has the OSK-103 wifi controller. From what I gather, the OSK-103 is not supported with direct wifi control, and so would have to install the “fake cloud” control server. I can’t find much info about the protocol this unit uses… has anyone implemented a home assistant module for this particular model?

If not – I’m thinking I would have to use the UART sniffer to suss out the commands?

I’m currently a homebridge user… but I’ve been looking at implementing home assistant for a while now, so guidance would be appreciated :slight_smile:

Hi @tehzimmy!

If you solder your own dongle as described in the start post of this thread and use the ESPHome component you are all set. The U-Shaped units are confirmed working with the ESPHome component. The official Midea app wont work any longer but since you can control it from HA this way you won’t be missing that.

Do you have Home Assistant already running?

I don’t have home assistant up and running yet, I just got around to setting up a headless mac mini to act as my server.

If I understand the HA environment, ESPhome is an integration that I can add to the HA services? Given that I’m coming from homebridge, I’ve written a few programs for things like light dimmers that utilize an ESP32 and are mqtt controlled (I have 12v puck LED’s that I wanted to control with homekit, made a mosfet based PWM driver connected to an ESP32, added MQTT library to the ino file and have mosquitto set up as a broker on homebridge).

Given this – I kind of like to understand the code that I’m using. I wouldn’t be opposed to just implementing code someone else has confirmed working… but I’m also curious to see if I could port it over to homebridge as a plugin.

Funny thing is, I can’t even get the midea app to connect to my network yet. I was going to check out it’s functionality first, and then transition to an ESP based control system, but the app just hangs at 99% when on the “configuring devices” step of the setup and never actually connects, so it’s just as well.

I’m also wary of “smart” things that need to phone home in order to function. I’d rather maintain direct control within my network.

I suppose my ultimate goal would be to understand the intermediate steps of how the ESP32 can control the AC unit, agnostic to the agent employed to send the commands. As I studied electrical engineering in my undergrad (no longer work as an engineer, however), I feel a little guilty about just taking a ready made solution without understanding how the “guts” work, if that makes sense?