Hi Everyone, Ive been working on this a little more and ended up rewriting a huge part of the current integration. I now have purify, self clean, steri clean, sleep, boost, quiet, display controls, and remote lock all working. Ive also worked to further the reverse engineering the communication messages.
Testing and feedback welcome. Timers and wifi light control are the main things i know are missing as of now.
I did do some reverse engineering, although I couldnāt get it to work to send any changes back. But maybe you have something of my ābitmapā here:
If not, no problem, checking for a minute canāt hurt.
I never used the integration you are working on, but might do in the future as i would like to do some automation with it, like drying when itās > 80% relative humidity. Or using another temperature sensor not in the airco itself.
Interesting, I hadnt seen your project till now, I didnt realize it would be so easy to sniff it from the network side of things! Quick glance at things shows that the network packets in your project seem to start with the temperature at byte 92, and in the uart side of things in my project they seem to start at 12. But they look to be the same or very similar!
Try the self clean, lock, unit bits on yours, they should work. Look at the haier .h and try some bits to see if they work for you!
Are you sure that byte 104 is humidity (byte 24 for me)? I have that marked as unknown in mine, i was thinking it might be the outside temp or something.
Edit: Just tried misting some water around the ac while it was running to see if byte 24 will change, it did not. I see a value of about 70 decimal that goes to about 63 when running in heat mode (makes sense as the outside unit will get colder) with an outside temperature of about 0-5c.
Have you looked inside your dongle to see what chipset its using? If its esp based, reflashing it should be easy, no need to use the official firmware since we already know how to control all the functions, plus that keeps everything local instead of it pinging home to haiers home servers.
Further to my earlier post, Iāve determined the cause of the lack of RX.
On Wemos 3.0 boards, the serial driver has an extremely powerful pull up resistor that the air-conditioner cannot overcome.
After testing with BSS138 the issue remained, but looking into things further I couldnt understand why the SN74 worked and resolved the issue while the BSS138 logic shifting did not.
All in all - to anyone else having problems, do NOT buy D1 3.0 boards - buy the older style modules with the soldered-on ESP module. They donāt suffer from this issue on their serial line.
I ordered and tested these older modules - worked perfectly and immediately with the BSS138 handling logic shifting.
@ceriel I suggest you try older boards if you did not already resolve your issues.
Now struggling with the same setup of wemos D1 mini v3.0 and BSS138-based shifter and the same symptomatic (no TX from AC). Whereās the pull-up resistor you mentioned is located? Maybe we can replace it with the lower-valued resistor or add the pull-down on the hi voltage (AC) side to reduce the current needed to pull the line down?
There were other sites too with mentions of high pull.
I did try reply and find out transistor values as my electronics skills arenāt what they once were, but thereās a schematic for a potential solution on that forum post. Only unknown is what transistors to try.
The software part. Have implemented the solution where the software uart (by esphome) is used on D6(RX) and D7(TX) pins but still canāt get the transmission from ACā¦ Sniffed the communication, and saw that the Wemos sends a āPOLLā command and AC responds to that command with bytes, but that bytes is not arriving to Wemosā¦
P.S.: a sniffer that was mentioned earlier in my post is built on ESP32 Nodemcu board with the same Sparkfun BSS138 level converter and is receiving data from BOTH RX AND TX lines successfullyā¦
Especially with currently rising electricity prices and as I use AC mainly as heat pump it would be nice to have some usable integrations, not what is in hOn or smartAir2 or in my case if some units use one app and others different, which makes it unusable really.ĀØ
I believe it wouldnāt be suitable for controlling an ac, i fear certain features would not be natively supported by zigbee and youd have to workaround to make it work. I believe ZHA has support for zigbee thermostats, but youd have to figure out workarounds for everything else the ac can do.
If you wanted to do that, youd need to make a ZigBee device that translates ZigBee commands to the custom serial commands the AC expects. I have not seen many examples of custom zigbee devices.
Yes, i currently use it on an esp01 board, i took the stock pcb, tapped into the 3.3v, gnd, rx, and tx from it, and tied its en line to disable the factory esp32 on it, then i had just enough room to squeeze the esp01 in there with the factory pcb.
Hi everybody. I have 3 Haier Flexis that i currently integrated in my Home Assistant using 3 ir smart remote (rm4 mini). The remote are working great but i hate this solution due the missing feedback from the AC unit. Iām trying to replace those using ESP Haier but unfortunatelly without any luck. I Tried both @MiguelAngelLV and @albertaCOM code using an ESP8266 D1 mini. I even tried using level shifters on both RX and TX without any luck. I keep seeing only POLL messages without any answer from the AC itself.
Any suggestion on what can i try next?
@ivoh95 Any chance to add position settings? Currently I added esp32 to the original module, it works but the original app give only a preview of a state, I cannot control unit anymore using hon as itās āfightingā with the added esp module. It would be perfect to be able to set specific position rather than swing.
@ivoh95 Iām using your code on an esp01 connected to the original esp32 board. If I disable the original board (using the EN pin) I donāt receive any status message, if I leave the board enabled I can read the status but canāt control the AC. Any idea?
Yesterday I finally tried this, found wemos d1 in the drawer, unfortunately version with no antenna, installed python, esphome, did esphome run stuff from original post, data are correctly read from the AC.
Iāve tried multiple versions (ivoh95 and albetaCOM) with an ESP32-DevKitC V4 with Haier Tundra Plus, also switched RX and TX to test, but doesnāt receive any correct messages. Next step is trying to spy on the messages.