Midea branded AC’s with ESPhome (no cloud)

Hello all.
I am using Mr cools midea clone with dudanovs USB stick and everything works like a charm.
And the thermostat that is available for it is also ok…
But how can one add a feature to it?
I find almost everything by default on the thermostat but not the toggle display to turn of the very bright temperature display on the unit.
On the device config page in esphome is this function working.
So can I somehow add this to the thermostats view or could I make a switch and somehow group it with the thermostat?
Thx for any thoughts

I bought the SMARTLIGHT SLWF-01 Pro v1.1 before knowing that some features were IR only.

I was hoping to not have to mess with with the minisplit board itself and just solder an IR transmitter to the SLWF-01. Do you know if that’s gonna work?

You should be able to pair this device locally via Matter without having to install the app of Midea. There is probably a QR code on the side of your device?

If you end up going to make yourself a dongle with local ESPHome control, I will happily buy your Matter dongle + QR code, as I accidentally bought one with the old stick and I want to test the Matter part.

Paulus
~Founder Home Assistant

1 Like

Are you still using your SK-109 dongle? Can I use it to test this AC via Matter in Home Assistant?

Paulus
~Founder Home Assistant

So I commented out those lines. It didnt change anything. I did however discover something strange going on. If I use the remote and set the display to F the numbers coming back to HA are in C in the logs but in the range of 197-221C where 197 corresponds to 62F and 221 to 86F. I then confirmed if I force one of these temp values back to the A/C using the on control lambda function, using 200C which corresponds to 65F then the A/C displays 65F. WTH? Complicating it more is that HA then converts that high number back to F so the dashboard says like 401F.

Can anyone help decipher this one? Is there some way to intercept and add offsets to the data to and from the esp?

Has anyone tried to connect any of the midea breezeless ac-s with floor mounted indoor unit?
i am looking into getting MFA2U-12HRFNX / MOX230-12HFN8, which does say optional Wi-Fi support, to which i assume could wire an esp.
of course, if it is somewhat of a given that i will get at least basic control over it, i will buy it regardless and report back :slight_smile:

I doubt I’ll ever use it again so you may have it. I did use it once to connect the a/c to Homekit via Matter before my ESPHome dongle showed up and it worked.

1 Like

After some testing using a kill-a-watt, it seems that the power consumption is accurate as long as the compressor isn’t working. For some reason when the compressor is running it’s roughly 1/3 of the actual value. I asked ChatGPT for assistance and this is what it suggested and so far is working great.

climate:
  - platform: midea
    name: "Upstairs Hallway A/C"
    period: 1s
    timeout: 2s
    num_attempts: 3
    autoconf: true
    beeper: false
    visual:
      min_temperature: 17 °C
      max_temperature: 30 °C
      temperature_step: 0.5 °C
    outdoor_temperature:
      name: "Outside Temp"
    power_usage:
      name: "Uncorrected Power Consumption"
      id: uncorrected_power_consumption

sensor:
  - platform: template
    name: "Corrected Power Consumption"
    unit_of_measurement: "W"
    lambda: |-
      if (id(uncorrected_power_consumption).state <= 15) {
        // When only the fan is running, no correction needed
        return id(uncorrected_power_consumption).state;
      } else {
        // When the compressor is running, apply correction factor
        return id(uncorrected_power_consumption).state * 3.33;
      }
    update_interval: 30s
    accuracy_decimals: 1

I think so. The SLWF-01 appears to expose GPIO and power pads for this purpose, but I think you’re not going to be able to drive the LED directly from the GPIO pad and you’ll need to use a transistor, so it wont be as simple as soldering two wires but I think it should work. I plan on doing this to mine one of these days.

Mostly because I have all the bits here already (except that plug). And because I didn’t want to wait. Even though of course DIY will somehow end up taking me even longer in the end. :smiley:

Search in your HA instance, maybe you missed it. I don’t think it will be part of the thermostat, but I don’t have anything working yet so I’m not sure. But search for a separate switch. And/or check your YAML config and make sure it’s enabled (or at least get the name to search in HA for). Other than that, maybe it’s not supported or a bug, but I would double (triple) check everything before assuming that.

Indeed, there is a QR code on the opposite side of the dongle. I was wondering if I could do something like that without Midea’s app. Neat!

Unfortunately no Matter here (yet), we are still primarily Zigbee. Although honestly the promise of local control might be enough motivation to dip my toe in the water, finally!

I see the other guy replied to you already. If you don’t connect with him, maybe I will send it to you. Although as I said, all of a sudden I am intrigued about Matter! :smiley: We will see what happens.

At some point in my research, I did notice that, in the parent generic ESPHome climate component it says:

In ESPHome, °C is assumed for all temperature values. Some platforms allow conversion or setting in °F, this is specified separately.

Perhaps a clue?


My project progressed a little. I found some 2.0 mm headers I had laying around, pulled the pins out with pliers and stuck them in (they fit). I then used some 2.0 mm to regular pin pitch duPont adapters I had also acquired for some other project. I used a little clear tape to help keep it together:

Then I spent the better part of 2 days studying ESPHome and thinking about my device and entity naming conventions. :smiley:

This will save you so much time in the future, you could have spent two weeks and it would still be worth it! :laughing: Assuming you came up with a good naming convention in the end… :rofl: :rofl:

1 Like

but I think you’re not going to be able to drive the LED directly from the GPIO pad and you’ll need to use a transistor, so it wont be as simple as soldering two wires but I think it should work

What’s making you think that? I ordered those IR transmitter and some jumper wires and will give it a shot when everything arrives.

Please keep us posted if you happen to try before I do.

This evening, I got mine working.

Here’s what I learned:

That 5 conductor wire is not the USB wire. There must be some little board in between the two. But I am only taking out a couple screws and gently prying at the front right area of my unit, so I’m very limited in what I can see and reach.[0]

I had tested for voltage on the 5-pin connector, but couldn’t find any. So I plugged it back together, then I got the expected 5VDC on the outer USB pins.

I then put everything together on a breadboard to test:

After some initial fits and starts[1], I was off to the races!

@topdog360, I have not tried to use the remote yet, but I did also experience some temperature weirdness (in the thermostat in HA web UI). After doing the following, it started working:

climate:
  - platform: midea
    # was originally:
    visual:
      min_temperature: 70
      max_temperature: 80
    # changed to:
    visual:
      min_temperature: 70°F
      max_temperature: 80°F

Now that I’ve proved to myself this works, I will work on miniaturizing it so I can tuck it back away in there nice and tidy (I did not have any ESP-01 on hand, but I will order some; or perhaps the Dudanov boards…).

I am also very seriously considering going out and buying 1 or 2 more of these units for other rooms in the house, and altogether stop using our extremely inefficient central A/C unit(!).

@balloob, If I do that, I should have 1-2 spares I could send you to play with. I’ll let you know.

Now, time for a celebratory cold one (or three)… :beers: :smiley:

[0] I had come across a pretty good teardown video for the Midea U-Shaped and I did not want to get into all that just yet, as my unit is still brand new.

[1] First I had logging enabled, which conflicted with the UART communication, so I disabled that. But I was still able to get logs via ESPHome wireless API (neat!). Then I realized I needed to flip TX/RX around.

1 Like

I don’t think the driver in the ESP32 can handle the current of the LED. I’ve only done this once (not on one of these dongles but on an Adafruit ESP32 development board) and in my research this is what I learned.

See this for reference

Typically the output of an Arduino type board does not have sufficient current to drive an LED so you need a driver circuit using a transistor.

It looks like maybe the transmitter you linked has all of that built in?

Got it. Honestly, I don’t know and i am winging this entire thing. I’ll give it a shot and report back whether or not I was successful.

Hi! Can you explain how do you do it???

thnks

Is it necessary to supply DE and RE ?

This works great but I’m experiencing an issue when setting min_temperature to 16.

The oddness comes because the UI keeps resetting the temp to 17C, on the web page of the dongle running ESP Home, and thus Home Assistant.

The AC stays at 16C, unless I turn it off and on again.

Anyone else seen this?

Hi all,

i am quite new, but i am as well interested in AC Dimstal to Home Assistant.

I running the “SMLIGHT.SLWF-01Pro” at the Dimstal Air Condition and it seems to work plug and play. I can switch it on and off and as well changing some settings.
But what i dont understand it seems that the step motor of the “air outlet control” shows a bit strange behavior now. It seems that the SLWF Stick runs other stepper values, so it can get now into a undbefined state where it still belives open and did not close completly. I hope you understand what i mean. By the way here are some debug messages of the module itself. Maybe u know something about this topic.

14:04:43	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:43	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:43	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:43	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9A 58 E6 
14:04:43	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 58 42 73 
14:04:43	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:43	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:44	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:44	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:44	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:44	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9B 06 37 
14:04:44	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 06 86 81 
14:04:44	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:45	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:45	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:45	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:45	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:45	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9C 85 B7 
14:04:45	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 85 E8 A0 
14:04:46	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:46	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:46	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:46	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:46	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:46	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9D DB 60 
14:04:46	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 DB 2C 06 
14:04:47	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:47	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:47	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:47	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:47	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:47	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9E 39 01 
14:04:48	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 39 79 5B 
14:04:48	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:48	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:48	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:48	[D]	[ApplianceBase:173]	
Enqueuing the request...
14:04:48	[D]	[ApplianceBase:075]	
Getting and sending a request from the queue...
14:04:48	[D]	[ApplianceBase:162]	
TX: AA 21 AC 8D 00 00 00 00 03 03 41 81 00 FF 03 FF 00 02 00 00 00 00 00 00 00 00 00 00 00 00 03 9F 67 D2 
14:04:49	[D]	[ApplianceBase:063]	
RX: AA 22 AC 00 00 00 00 00 03 03 C0 00 41 28 7F 7F 00 30 00 00 00 5A 6E 00 00 00 00 00 00 00 00 00 67 BD E9 
14:04:49	[D]	[AirConditioner:205]	
New status data received. Parsing...
14:04:49	[D]	[ApplianceBase:154]	
Destroying the request...
14:04:49	[D]	[AirConditioner:178]	
Enqueuing a GET_STATUS(0x41) request...
14:04:49	[D]	[ApplianceBase:173]	
Enqueuing the request...

have you figured it out? I am also stuck on this one