Closed Bladestar2105 closed 1 year ago
Hello,
I don't have a Opener so I cannot test it, I will look into it anyway but I probably will need some help from you while debugging.
For start the software automatically you can create a systemd service, I will add a small guide to the readme in the next days
Tell me what you need and I can help you :-)
Were you able to pair the opener with the software? what kind of issues are you having?
And another question. How can I enable it so it autostarts when my Linux comes up?
Added instructions for this in the README
Hi, I just found your repo and I'm getting an opener soon and want to use some kind of software bridge. I will try it out and would be happy to help adding support for the opener :)
Found the documentation for opener: https://developer.nuki.io/page/nuki-opener-api-1/7
I see that there are not many differences from the smartlock, you should be able to pair the opener with the software. Can you confirm this? after this I'll add the missing actions for the opener
Sounds promising, I haven't tried or even installed your software yet. I will try today evening or tomorrow morning and will give an update.
It took me a few tries, but it seems to have worked.
Output in a pastebin as I am too stupid to properly format in here 😂 https://pastebin.com/K8AG1fNK
Edit: Also it stays at the last line until I quit.
So, this happens while trying to pair the opener?
So, this happens while trying to pair the opener?
Exactly. Took me a few times to get it to kinda pair tho.
The pairing seems to not be completed, I'll look into it. Please try to run the pairing command with the --verbose flag to have more logs (remember to hide any personal information in it)
Please try to run the pairing command with the --verbose flag to have more logs (remember to hide any personal information in it)
It seems like it doesn't make any difference using --verbose flag. Output is exactly the same.
So, it seems the software cannot find the ble characteristic used by the pairing process (but on the docs it's the same as the smartlock, so that's strange). Anyway I just added some verbose logs so, if you can, update and try again with the verbose logs flag please
I'll try again with verbose logs once I get home!
Here you go: https://pastebin.com/Q8GUcZ0m
uhm, It seems the values of the characteristics in the official docs are wrong?
Can you please try to edit the file nuki.py
and change these lines:
BLE_SERVICE_CHAR = "a92ee202-5501-11e4-916c-0800200c9a66"
BLE_PAIRING_CHAR = 'a92ee101-5501-11e4-916c-0800200c9a66'
with these:
BLE_SERVICE_CHAR = "a92ae202-5501-11e4-916c-0800200c9a66"
BLE_PAIRING_CHAR = 'a92ae101-5501-11e4-916c-0800200c9a66'
and run it again?
uhm, It seems the values of the characteristics in the official docs are wrong?
Interesting 🤔😂
Got another error now: https://pastebin.com/RuJpicRq
It seems the error is that the opener isn't in pairing mode. You should press the button on the opener for 5 seconds in order to set it in pairing mode, did you do this?
It seems the error is that the opener isn't in pairing mode. You should press the button on the opener for 5 seconds in order to set it in pairing mode, did you do this?
I guess I didn't press long enough. Now it seems to look better: https://pastebin.com/QSu9VmBH
yes, that's good! the pairing process is completed, you can copy the info in the yaml file (as explained in the readme) and start the software.
So the communication is working but the format of the CONFIG message is different (the HomeKit status field is missing). I'll work on this and consolidate the different characteristics values we found. Probably updating tomorrow ;)
Makes sense as the opener is not supported by homekit at all.
Thanks! Let me know when to update and try again! :)
You can update the software and try again
You can update the software and try again
Seems like the same problem as yesterday when pairing https://pastebin.com/zTsf1gTL
It seems that there are problems with the pairing procedure but you already paired it yesterday, so It should be not necessary to do it again. can you start the software normally? (I'll fix the pairing procedure in the meantime)
I did a fresh start by downloading the repo again into a new folder, so I guess I have to pair it again first, sorry.
ok, i think i fixed it, try again please
It generates the keys and then seems to be stuck on
2022-04-01 16:02:28.544|I|nuki.py:555|Device type: DeviceType.OPENER
EDIT: Added --verbose flag, stuck on
2022-04-01 16:06:33.407|D|nuki.py:466|Sending data to a92ae101-5501-11e4-916c-0800200c9a66: b"\x01\x00\x03\x00'\xa7"
updated, try again please
Pairing completed. When starting the software its saying this in a loop (added the opener as smartlock, as it seems to expect a smartlock in the yaml):
First time starting the software it also says Device XX:XX:XX:XX:XX is SMARTLOCK_1_2
before "Updating nuki state"
Updated the code, please try again!
Done. It's still correct that I'm using 'smartlock' in the yaml right?
It's still correct that I'm using 'smartlock' in the yaml right?
yes, don't worry about that.
Looking at your logs it seems the software now correctly identify the device as the opener, and it's using the correct configuration mapping values (the one without the homekit status) but still it seems there is something different. can you try to run it with the verbose flag?
Okay, sry I didn't know there is a verbose flag for the script itself too (as it is already paired). But I ran with verbose now: https://pastebin.com/QY1DuagY
good, I've probably found the problem, try again please
Looks good to me, it's getting the name, location etc from the opener and stays at the last line without error or exiting.
What would be the next step?
perfect! next step would be to try some actions on the opener. Are you planning to integrate this bridge with homeassistant, openhub or something like that?
I want to add it to homeassistant, yes :)
well you can already do it, just configure the official integration using the ip address of your raspberry and the token that is saved in your nuki.yaml file. let's see if it works!
Works, but without any entities or devices.
any errors in the software logs?
In ha logs it only says unknown device type: 1. Using the official integration.
ye, my DeviceType mapping was incorrect :( Try to update the software and retry please
It seems to be still the same. I'll try again tomorrow tho, unless you find something.
shoud be fixed now
shoud be fixed now
Now it just says canceled when setting up the integration. Logs are empty.
The last edit was really a minor one, it shouldn't cause issues like this without some errors in the logs. Try to remove the integration, restart the software and homeassistant and try it again.
I restarted HA again, reenabled the previously deactivated integration and it now shows one entity. But it says locked, even tho it's an opener and not a lock.
Hello!
Your Bridge works very well with the smartlock! Could you please implement support for the opener?
And another question. How can I enable it so it autostarts when my Linux comes up?