dennis1804 / homewizard-climate-hass

12 stars 6 forks source link

Princess Smart Fan 35000 Support #17

Closed kevjs1982 closed 4 months ago

kevjs1982 commented 10 months ago

I've got a Princess Smart Fan 35000 https://www.amazon.co.uk/dp/B07PKR381W (01.350000.02.001) and it kinda works with Home Assistant - but the mode selection doesn't seem to work properly - you can't select the "Comfort" mode at all and it keeps reverting to Eco in the Home Assistant UI. The Oscillation also can't be turned off (can be turned On in home assistant, but the UI reverts to "Off" while the Oscillation kicks in.

I'm assuming the mode is because Comfort/Eco/Sleep are the options where as my device supports Natural/Normal/Sleep

I've been able to connect to the websocket and the following are the responses to switching between all the different modes on device - All the #'s below are where I have blanked out identifying information.

{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":0}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":480}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":420}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":360}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":300}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":240}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":180}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":120}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":60}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/timer","value":0}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/oscillation","value":false}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/oscillation","value":true}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/mode","value":"natural"}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/mode","value":"normal"}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/mode","value":"sleep"}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/speed","value":1}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/speed","value":2}]}
{"type":"json_patch","device":"FAN##########","patch":[{"op":"replace","path":"/state/speed","value":3}]}
{"type":"fan","device":"FAN##########","state":{"power_on":true,"oscillation":false,"timer":0,"mode":"normal","speed":2},"name":"Bedroom Fan","online":true}
Connected to wss://app-ws.homewizard.com/ws

list of devices https:// request returns

{
    "account_id": ###################,
    "account_uuid": "###################",
    "link_challenge": "###################",
    "devices": [
        {
            "name": "Bedroom Fan",
            "identifier": "FAN##########",
            "grants": null,
            "type": "fan",
            "endpoint": null
        }
    ],
    "cameras": []
}

Is this enough information to complete the support for it or is there something else you need provided? (All requests made via Postman after reading the Python code & a bit of trial and error).

dennis1804 commented 10 months ago

Yes that's enough for now, sorry for the late response, had some other things to do. I have to park it until I have fixed #11, otherwise adding this doesn't make any sense :)

Pascal4Games commented 6 months ago

I have the same device and in the latest version d906d76 it should work completely (except timer). But I cannot test this because it does not work from the climate app. I have not yet found out whether this is a home wizard problem or a local network problem.

Edit: Today I received a message from Homewizard that the connection problems had been resolved. Fan checked and I think all functions work. Topic can be closed?

kevjs1982 commented 4 months ago

I can confirm this is now working with the latest updates