Midea branded AC’s with ESPhome (no cloud)

no…you still need the level shifter…
Actually, what you’re doing could damage the AC (or wemos/nodemcu), as the AC connector is NOT USB…
Here someone who managed to get it going on wemos:
image

You can check the ESPHome logs…this is how it should look like:

1 Like

@aceindy i’m using a nodeMCU, nor a Wemos.

i was referring to the usb connector and level shifter
but…fine…edited the reply in wemos/nodemcu😉

You’re not leveling the voltage correctly. :slight_smile:

A/C = 5V
NodeMCU = 3.3V

NodeMCUs should be able to work with 5V, but it is not good for your board. And the possibility for errors grows…

And don’t confuse the power to run your board with the voltage that is needed to speak to each other. The communication is 5V here, so a level shifter is really a good idea. :slight_smile:

@aceindy sorry, i was going totally stuck.
@paddy0174 the point is only the different voltage? i can use a step down… or there are other troubles?
BTW i can use another board, as long as is available via amazon in 1-2 days. Some suggestions?

nodemcu should work, but you should not use the micro-usb connector, but looks like nodemcu has tx/rx available on gpio1/3, advise to use those (with level shifter)
9b85dc9ed38064469d67b07e9beb598e

i use still the esp01s with it’s own levelshifter…
works fine and is by far the cheapest :wink:

A step down is the right direction, but not the right product. :wink: :slight_smile:

You need a level shifter (these are available on Amazon as well). I’ll try to explain a little more:

You have four wires:
red = 5V
black = ground (5V)
green = TX <= and here is your culprit, these TX (talking) line needs 5V as well
white = RX <= this is in 5V as well

The communication lines normally are 3.3V, not 5V, even if the board is powered by 5V. You get the idea. :slight_smile:
That’s why you need a level shifter, that can turn both directions (TX and RX) into 5V. With a step down you only lower the voltage to power your board, but that has nothing to do with the voltage on the communication lines. :slight_smile:

1 Like

i’m going to buy 5 ESP-01s , 5 ESP-01 serial to serial board and 1 ESP-01 usb adapter. so i’m settling things once and for all.
Someone knows the name of the white header used at the end of the “usb to logic board” connector on the AC?
XH2P ?!
FOUND! JST-XH

1 Like

This ‘generic dupont set’ female-female works nice

can I have a picture of your logic board > adapter ? I’m curious :thinking:

See post 1….still using the same as when i started.
i cut my dupont cables, after i found a fit header plug on some old pcb…but dupont would fit both sides (tip, use super glue to head them together :wink:)

I’m thanking @aceindy @paddy0174 @n1k5y
for patience and helpfulness. I’m totally unready and beefeding but you are continuing to supporting me.

Rebecca

Let us know how things work out! :slight_smile:

Btw. I’m using the exact same components as aceindy, I just pushed the female connectors directly onto the pins (of the A/C and the ESP).

Running for more than half a year without any problems. :wink: Even not updated, as I’m way too lazy to update via FTDI (OTA is not available with my small ESP)…that would mean I need to climb up to the A/C, disconnect and so on. Must wait until the end of summer, when I clean my A/C to shut it down for the winter. :slight_smile:

I tried on a spare esp, and ota works nowadays (only took me a while to actually swap them :thinking:)….i guess the original bins we created with the devs repository was bigger than the main repository is now :nerd_face:

1 Like

Some ESP-01S and own serial to serial shifter board as come home, so I generated a suited ESPhome config and tried to installing it on the chip using a generic CH340G and a generic PL2303 USB to TTL, with and without the serial/serial shifter board, but ESPhome dashboard failed the installation, refusing the connection.
Perhaps the original ESP-01 USB to TTL is needed?

I’m using this adapter to flash my ESP boards. I have the CH340G as well, but couldn’t get it to work. :wink:

EDIT: @aceindy Just tried to flash OTA, still no joy… :frowning: I’ll test with a stripped down file (only OTA) ad try again. Otherwise I’ll need to check if I can use the logic level shifter with an ESP32 (found one lying around in the garage shop :rofl: :rofl:

@paddy0174 I had to use an empty ESP01 ( as the one in use has too little RAM available)
But with this image i can reflash over and over

I connected the nodeMCU to AC via ESP-01’s logical shifter board and i think it’s found/recognised by the AC’s logic board, because the WI-FI icon on the display lights up 30/40s: as the same time as other ACs mounting the original MIdea key, but HA still not able to manage the “modded” AC (Disimpegno).

Overview Dashboard
immagine

Configuration Entities Dashboard

Configuration Devices Dashboard

Current nodeMCU’s ESPhome configuration

esphome:
  name: midea-disimpegno
  platform: ESP8266
  board: nodemcuv2

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:
  password: "Flying"

wifi:
  ssid: "Foo"
  password: "Bar"
  manual_ip:
    static_ip: 192.168.1.76
    gateway: 192.168.1.3
    subnet: 255.255.255.0


  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Midea-Disimpegno"
    password: "ddl8nnCpqVCT"

captive_portal:


# UART settings for Midea dongle (required)
uart:
  tx_pin: GPIO1
  rx_pin: GPIO3
  baud_rate: 9600
  
# Optional (if you want modify settings)
midea_dongle:
  strength_icon: true 
  
# Main settings
climate:
  - platform: midea_ac
    name: Condizionatore Disimpegno    # Use a unique name.
    beeper: true                # Beep on commands.
    
   
    visual:                     # Optional. Example of visual settings override.
      min_temperature: 16 °C    # min: 16
      max_temperature: 30 °C    # max: 30
      temperature_step: 0.5 °C  # min: 0.5

    swing_horizontal: true
    swing_both: true
    outdoor_temperature:
      name: "Temperatura Unità Esterna"
    power_usage:
      name: "Consumo Condizionatore Disimpegno"
    humidity_setpoint:
      name: "Umidità Condizionatore Disimpegno"

There are some other items that can be useful for troubleshotting?

:slight_smile: Go to your ESPHome dashboard (in your left pane “ESPHome”):

  • What does the status icon/bar say for your node? Is it “online/offline/unknown status”?
  • If online, press the “LOGS” button for your node.
  • Choose the wireless connection.
  • A pop-up should open, there you have the ESP logs.
  • Post the first 80 to 100 lines from the log. Hint: the log scrolls automatically, if new entries are coming in. Just scroll up in the log window and it will stay at that line. New lines will be added, but it will not scroll automatically.

despite the nodeMCU being online


the logger can’t reach it

INFO Reading configuration /config/esphome/midea-disimpegno2.yaml...
INFO Starting log output from 192.168.1.76 using esphome API
INFO Connecting to 192.168.1.76:6053 (192.168.1.76)
WARNING Initial connection failed. The ESP might not be connected to WiFi yet (Error connecting to 192.168.1.76: [Errno 111] Connection refused). Re-Trying in 1 seconds

in the ESPhome device config i have

# Enable logging
logger:

Is that section incomplete ?