Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for air-to-water heatpump #43

Open
TheEris opened this issue Dec 2, 2021 · 2 comments
Open

Support for air-to-water heatpump #43

TheEris opened this issue Dec 2, 2021 · 2 comments

Comments

@TheEris
Copy link

TheEris commented Dec 2, 2021

Hey!
I've got myself a few months back a heat pump from Sinclair (model: smh-100irb and smh-60irb) and it didn't work out of the box with the gree-remote or any other gree-variant (HomeAssistant plugin or ewpe-smart-mqtt) so I've started digging. Here is the complete flow I was able to dig out from the EWPE Smart app with Wireshark (the heat pump is there as "ATW HP").
All the pack data is decrypted for easier reading.

the initial discovery of the device via UDP broadcast

send:
{
  "t": "scan"
}

received data: (decoded with key "a3K8Bx%2r8Y7#xDh")

{
    "t":"pack",
    "i":1,
    "uid":0,
    "cid":"<MAC>",
    "tcid":"app",
    "pack":"{
        "t":"dev",
        "cid":"<MAC>",
        "bc":"gree",
        "brand":"gree",
        "catalog":"gree",
        "mac":"<MAC>",
        "mid":"9300",
        "model":"gree",
        "name":"",
        "series":"gree",
        "vender":"1",
        "ver":"V5.0.0.0",
        "lock":0
    }"
}

send: (encoded with key "a3K8Bx%2r8Y7#xDh")

{
    "cid": "app",
    "i": 1,
    "pack": "{
        "mac": "<MAC>",
        "t": "bind",
        "uid": 0
    }",
    "t": "pack",
    "tcid": "<MAC>",
    "uid": 0
}

received data: (decoded with key "a3K8Bx%2r8Y7#xDh")

{
    "t":"pack",
    "i":1,
    "uid":0,
    "cid":"<MAC>",
    "tcid":"app",
    "pack":"{
        "t":"bindok",
        "mac":"<MAC>",
        "key":"<KEY>",
        "r":200
    }"
}

got key "KEY"
Now I was able to read the status and temperature of the heat pump.
This part took me the longest as I had to figure out the new object names.

send: (encoded with key "KEY")

{
    "pack":"{
        "t":"status",
        "mac":"<MAC>",
        "cols":[
            "AllInWatTemHi",
            "AllInWatTemLo",
            "AllOutWatTemHi",
            "AllOutWatTemLo",
            "HepOutWatTemHi",
            "HepOutWatTemLo",
            "WatBoxTemHi",
            "WatBoxTemLo",
            "RmoHomTemHi",
            "RmoHomTemLo",
            "WatBoxElcHeRunSta",
            "SyAnFroRunSta",
            "ElcHe1RunSta",
            "ElcHe2RunSta",
            "AnFrzzRunSta",
            "TemUn",
            "AllErr"
        ]
    }",
    "i":0,
    "cid":"app",
    "uid":0,
    "tcid":"<MAC>",
    "t":"pack"
}

received data: (decoded with key "KEY")

{
    "t":"pack",
    "i":0,
    "uid":0,
    "cid":"<MAC>",
    "tcid":"app",
    "pack":"{
        "t":"dat",
        "r":200,
        "mac":"<MAC>",
        "cols":[
            "AllInWatTemHi",
            "AllInWatTemLo",
            "AllOutWatTemHi",
            "AllOutWatTemLo",
            "HepOutWatTemHi",
            "HepOutWatTemLo",
            "WatBoxTemHi",
            "WatBoxTemLo",
            "RmoHomTemHi",
            "RmoHomTemLo",
            "WatBoxElcHeRunSta",
            "SyAnFroRunSta",
            "ElcHe1RunSta",
            "ElcHe2RunSta",
            "AnFrzzRunSta",
            "TemUn",
            "AllErr"
        ],
        "dat":[
            132,
            4,
            132,
            2,
            70,
            0,
            100,
            0,
            70,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0
        ]
    }"
}

input water temp: (dat[0]-100)+dat[1]*0.1 = 32.4
output water temp: (dat[2]-100)+dat[3]*0.1 = 32.2
same goes for other variables that have two parts wih Hi-Lo ending
(HepOutWatTem shows -30 because i dont have it configured)

send: (encoded with key "KEY")

{
    "pack":"{
        "t":"status",
        "mac":"<MAC>",
        "cols":[
            "Pow",
            "Mod",
            "CoWatOutTemSet",
            "HeWatOutTemSet",
            "WatBoxTemSet",
            "TemUn",
            "TemRec",
            "AllErr",
            "host",
            "name",
            "ColHtWter",
            "HetHtWter",
            "LefHom",
            "TemRecB",
            "RomHomTemExt",
            "CoHomTemSet",
            "HeHomTemSet"
            ]
    }"
    "i":0,
    "cid":"app",
    "uid":2179292,
    "tcid":"<MAC>",
    "t":"pack"
}

received data: (decoded with key "KEY")

{
    "t":"pack",
    "i":0,
    "uid":2179292,
    "cid":"<MAC>",
    "tcid":"app",
    "pack":"{
        "t":"dat",
        "r":200,
        "mac":"<MAC>",
        "cols":[
            "Pow",
            "Mod",
            "CoWatOutTemSet",
            "HeWatOutTemSet",
            "WatBoxTemSet",
            "TemUn",
            "TemRec",
            "AllErr",
            "host",
            "name",
            "ColHtWter",
            "HetHtWter",
            "LefHom",
            "TemRecB",
            "RomHomTemExt",
            "CoHomTemSet",
            "HeHomTemSet"],
        "dat":[
            1,
            1,
            18,
            35,
            50,
            0,
            0,
            0,
            "eu.dis.gree.com",
            "",
            0,
            0,
            0,
            0,
            0,
            24,
            20
            ]
    }"
}

it would be nice if you could integrate this into the gree-remote. In the end, I would love it to work with Home assistant.

@rubenRP
Copy link

rubenRP commented Feb 11, 2023

Hello @TheEris. I'm developing a Homebridge plugin for Gree ATW and I'm interested in all the Status View Params (Specifically, compressor, fan and HP-pump). Have you been able to identify them, or do they not exist?

@TheEris
Copy link
Author

TheEris commented Feb 11, 2023

@rubenRP Thats awesome, sadly this is everything ive managet to found out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants