andersonshatch / midea-ac-lib

Library for controlling Midea AC devices via their cloud
MIT License
21 stars 6 forks source link

Feature request: direct communication to the device (bypass Midea altogether) #2

Open velaar opened 4 years ago

velaar commented 4 years ago

I did some packet captures of communication between the cloud and the device and seen the strings similar to this:

c00087667f7f003c0000006347000000000000000000006c3000000000000000000000000000000000

It seems that the format is very similar to what we send/receive from the cloud. Will it be possible to bypass the cloud somehow?

p.s. I am using this module with a Senville Aura AC (https://senville.com) and it works very well, it might be worth noting in the README that non-idea ACs are compatible.

andersonshatch commented 4 years ago

Just moving this over from the home-assistant component to the underlying library which currently uses their cloud. I agree this would be nice. Did you try sending any commands directly? I think the original ruby project's github has some research on this, but not sure it was put into practice yet and I've not personally looked into it.

mrueg commented 4 years ago

I've found https://github.com/mac-zhou/midea-msmart/ this weekend. Maybe @mac-zhou and @andersonshatch will be able to integrate that into a single library or a single homeassistant component?

jonatino commented 3 years ago

@velaar did u ever find a way to control your Senville aura series? I'd love to integrate with home assistant but can't find any solutions.

velaar commented 3 years ago

@velaar did u ever find a way to control your Senville aura series?

The solution above works for me. https://github.com/mac-zhou/midea-ac-py Wifi modules are not great in terms of reliability but at least the component above provides direct (no cloud or even internet access) control.

jonatino commented 3 years ago

@velaar what model do you have? When I run the discover script mine comes back as unsupported.

user@pop-os:~$ midea-discover --debug
INFO:msmart.cli:Debug mode active
INFO:msmart.cli:msmart version: 0.1.24
INFO:msmart.cli:Sending Device Scan Broadcast...
INFO:msmart.cli:Midea Local Data 10.0.0.252 837000b8200f04045a5a0111a8007a80000000000000000000000000856b0100000e0000000000000000000000000000dc449482eb2a18046c25f9d6f40040bb7c5179b1de29da3850d76d9beb6696c43c62647f4cd2d2970bc61b40da818a41fc8e848a4e8dd114460862be7fde510a2a78f6fe90fe0607a7e5ae341e42aa7a27894ab6cf71c28b56b12c3c424196e7f31443d17c3aac03a7656614ae1dca4494835a2972a432f24b9ef863206fce4530ad07ec1162951f501b492fb9432443
INFO:msmart.cli:Decrypt Reply: 10.0.0.252 fc00000a2c19000030303030303050303030303030305131353032444242353933383441303030300b6e65745f61635f333834410000000001000000040000000000ac00000000000000502dbb59384a069fcd0400020103000000000000000000000000000000000000000000
DEBUG:msmart.command:Finalize request data: aa20ac00000000000003418100ff03ff000200000000000000000000000003cd9c
DEBUG:msmart.lan:Sending to 10.0.0.252:6444 5a5a0111680020000000000026030f0c0f061514856b0100000e00000000000000000000000000006b000a76e27eed2c3647e57d8602df8bc4af172d627dc261b35011770d1013062a3b1c43d2f1c08ae8768502a22a836b194afc4687f3bb44c6b38740a6929555
INFO:msmart.lan:Couldn't connect with Device 10.0.0.252:6444
DEBUG:msmart.device:refresh - Recieved from 10.0.0.252, 856b0100000e: 
INFO:msmart.cli:*** Found a unsupported device - type: '0xac' - version: V3 - ip: 10.0.0.252 - port: 6444 - id: 16593134881925 - sn: 000000P0000000Q1502DBB59384A0000 - ssid: net_ac_384A
user@pop-os:~$ 
aa755 commented 3 years ago

you can control it in a wired way: https://github.com/mac-zhou/midea-ac-py/issues/33