Hernas / homebridge-salus-sq610

Apache License 2.0
8 stars 4 forks source link

New Salus AWS plattform #5

Closed california444 closed 1 week ago

california444 commented 7 months ago

Hi @bimusiek, do you now if it is save to switch to new Salus AWS Plattform? Have you migrated already? Does the plugin still work?

thanks!

bimusiek commented 7 months ago

I have heard from one user about it and tried to quickly fix it but did not have time yet. This looks similar to Panasonic Comfort Cloud issue, so please be patient.

california444 commented 7 months ago

So it is more than changing the URL in the config?

bimusiek commented 7 months ago

Unfortunately yes, Salus changed how the auth works. You can already change the url in config because I thought that would be enough.

california444 commented 7 months ago

looks like they are now using AWS Cognito. I can see a AWSCognitoIdentityProviderService.InitiateAuth (with "AuthFlow":"USER_SRP_AUTH"), followed by a AWSCognitoIdentityProviderService.RespondToAuthChallenge and a AWSCognitoIdentityService.GetCredentialsForIdentity

pettersandholt commented 5 months ago

Any update on this? Would be amazing to get it working again :)

mjrybarski commented 2 months ago

still no updates? old platform is down for good i guess so now is only https://eu.premium.salusconnect.io

bimusiek commented 2 months ago

Unfortunately due to other issues with homebridge I have switched to HomeAssistant. It has much better support for smart homes configurations and it has already existing Salus plugin that works locally.

I could take a look at their sourcecode and implement the same for this plugin but I don't have the time as of now.

RockstarRebell commented 2 months ago

Hi Bimusiek, it would be great if you could if you could fix it! Thanx a lot! Greetings

PuscasAdi commented 2 months ago

Unfortunately due to other issues with homebridge I have switched to HomeAssistant. It has much better support for smart homes configurations and it has already existing Salus plugin that works locally.

I could take a look at their sourcecode and implement the same for this plugin but I don't have the time as of now.

Can you please attach the link to the HomeAsssistant SALUS plugin?

bimusiek commented 2 months ago

https://github.com/epoplavskis/homeassistant_salus I am using this one.

Moater11 commented 1 week ago

Hi there. Any chance we can get this plugin working again via Hoobs? Many thanks.

california444 commented 1 week ago

HI, I was curious to understand why and how the home assistant plugin works with the new platform... The difference to this plugin is, that they do not use the cloud platform at all, but make requests to the UGW in the local network. I then spent a lot of time to figure out how to port the encryption algorithm from pyhton to Javascript. I finally managed to make the encrypted API calls and retrieve data from UGW directly for my thermostats. The data structure seems a bit different (but not too different...). Yesterday evening I started to port my quick and dirty JS code into Typescript and to integrate it into the structure of this plugin.

@bimusiek are you open for a PR changing from cloud platform with user and password to local connection with ip address and EU-ID of the UGW? It is still work in progress on my side and I am quite busy with other things. But I hope to be able to make an initial suggestion in the next days if everything's works as I expect...

california444 commented 1 week ago

fyi https://github.com/california444/homebridge-salus-sq610

There is a draft version, which is "working":

Might still be a bit buggy und not very well tested....

RockstarRebell commented 1 week ago

Hallo california444, thanks so much for your work! I tried for 3 hours with help from chatgpt but i'm nor able to install the draft version correctly. It doesn't work.
"No plugin was found for the platform "SalusSQ610HomebridgePlugin" in your config.json. Please make sure the corresponding plugin is installed correctly."

pi@homebridge:/var/lib/homebridge $ /opt/homebridge/bin/npm uninstall -g @hernas/homebridge-salus-sq610

removed 1 package in 2s pi@homebridge:/var/lib/homebridge $ /opt/homebridge/bin/npm cache clean --force pi@homebridge:/var/lib/homebridge $ /opt/homebridge/bin/npm install -g california444/homebridge-salus-sq610

added 16 packages in 18s pi@homebridge:/var/lib/homebridge $ /opt/homebridge/bin/npm list -g --depth=0 /opt/homebridge/lib ├── @hernas/homebridge-salus-sq610@ ├── corepack@0.29.3 ├── homebridge-config-ui-x@4.62.0 └── npm@10.8.2

ChatGPT said that a version-number is missing.

california444 commented 1 week ago

HI @RockstarRebell , yeah, I am not an expert with npm, but I get the same issue when I repeat your steps and try to install it directly from Github. So I pushed the current version to npm. You should now be able to search within homebridge UI:

image

Also you need to change your config. Add the ip address of your local Gateway and either try eu_id: 0000000000000000 or if this does not work, check the eu_id mentioned on the bottom side of the gateway

{ "ip_address": "192.168.0.88", "eu_id": "0000000000000000", "refreshTime": 60, "platform": "SalusSQ610HomebridgePlugin" }

bimusiek commented 1 week ago

@california444 if you create the PR, I am happy to merge and test it.

RockstarRebell commented 1 week ago

It works! 🤩 thank you so much!

california444 commented 1 week ago

Glad that it works… I will try to create the PR soon here…

california444 commented 1 week ago

here we go: https://github.com/Hernas/homebridge-salus-sq610/pull/7