-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
Implement new device types (available since 2 weeks) #74
Comments
This would be very much appreciated! |
Do the two new types handle any different than a standard lock on the API ? Do you maybe even have a door or the new SmartLock to test this? |
No, they behave exactly the same as the standard ones. Just the types have to be set, all else is identical. |
Yes, please test it. It's already merged into this branch. Just pull pynuki=1.5.0.
The Lock should be listed there. |
Can I install it as a repository via HACS? |
you would need to update the dependency manually if you want to test it inside HomeAssistant (or just wait for the update to get merged) |
Then I will have to wait, as I am not set up for that. |
The new HomeAssistant release is out, which contains this change. Could you test it? |
Works fine now! Thanks for that! |
It didn't work for me... it tries to send to deviceType = 0 but I have a devicType 4 (3.0 Lock) running HomeAssistant core-2022.3.4 and tried 3.5 I think the problem is in the request url while locking |
Hey, I created a Pull Request with a working version for my locks. |
Hi, I'm waiting for the upgrade-program to switch from v2.0+bridge to v3.0pro. Now I just saw the Q&A on nuki.io:
Could this be an issue? Best regards |
Yes, even if you have the 3.0 Pro Lock you still would need the bridge to be able to use the local API. |
Just returned my 3.0 Pro lock in favor of the regular 3.0 + bridge because the pro doesn't have local API. Simpler to go that route than to wait and see if they add the local API for the pro version. |
Nuki Bridge HTTP API V1.13.1 introduced 2 new device types, which the actual version does not support. As I found out, the implementation of Nuki integration in Home Assistant relies on your work, so probably update this library will fix the issues in HA ... thank you!
https://developer.nuki.io/page/nuki-bridge-http-api-1-13/4/
My Python skills are not good enough to supply a complete fix, but this could be a simple option. A better option would be to add an array that contains all supported device types, but that's probably more complicated...
pynuki/constants.py
After line 22, add:
DEVICE_TYPE_SMARTDOOR = 3
DEVICE_TYPE_NEWLOCK = 4
pynuki/bridge.py
After Line 218, add
elif dev_type == const.DEVICE_TYPE_NEWLOCK:
//modify data that device_data.get("deviceType") gives back 2 instead of 3 ... no idea how that is done in Phyton :-(
dev = NukiLock(self, data)
elif dev_type == const.DEVICE_TYPE_NEWLOCK:
//modify data that device_data.get("deviceType") gives back 2 instead of 4 ...no idea how that is done in Phyton :-(
dev = NukiLock(self, data)
The text was updated successfully, but these errors were encountered: