I get those as well… when that happens normally for me things are working.
Try to scan on the addon a few times. it might be that insisting will work.
But my expectation is that when you press scan on the addon a bunch of messages show on the gateway
the only thing I could do is add a fingerprint ID
cannot add card or passcode
operation failed
also when I try to unpair, it does not allow me to unpair
so far you have been amazingly helpful … I appreciate your help
I have been trying to get this to work for a while. I have to use the gateway option as my HA install is in a VM. Therefore I have built a gateway on a RPI as per the instructions above.
However I cannot get the lock to appear in the Add In.
Replying to my own message, running the debug options I see this error:
uncaughtException catch: unhandledRejection
TypeError: Converting circular structure to JSON
--> starting at object with constructor 'Timeout'
| property '_idlePrev' -> object with constructor 'TimersList'
--- property '_idleNext' closes the circle
at JSON.stringify (<anonymous>)
at TTLock.toJSON (/app/node_modules/ttlock-sdk-js/dist/device/TTLock.js:1340:25)
at Manager._onFoundLock (/app/src/manager.js:695:50)
at TTLockClient.emit (node:events:519:28)
at TTLockClient.onScanResult (/app/node_modules/ttlock-sdk-js/dist/TTLockClient.js:163:22)
at BluetoothLeService.emit (node:events:519:28)
at BluetoothLeService.onDiscover (/app/node_modules/ttlock-sdk-js/dist/scanner/BluetoothLeService.js:52:18)
at NobleScannerWebsocket.emit (node:events:519:28)
at NobleScannerWebsocket.onNobleDiscover (/app/node_modules/ttlock-sdk-js/dist/scanner/noble/NobleScanner.js:100:22)
at Noble.emit (node:events:519:28)
It certainly looks like you are almost there if you’re seeing startScan/ discover /stopScan messages.
Has the lock been RESET? My understanding is that the lock only appears if it is completely free of any previous pair connection. In other words you have to RESET it with the ‘reset button procedure’.
In my case (yours might be different, not sure what type of lock you have) I hit the reset button inside the battery compartment for 5s and then had to enter admin code ‘000#’ to complete the RESET process.
My lock has a ‘speaker’ so it prompts me during this process for the admin code.
Once a lock has been reset (is no longer linked to any previous gateway/phone), touching the pin pad results in a prompt via speaker to “start Bluetooth administration’ or something like that. This is essentially saying the lock is now in pairing mode. It does not last that long so you need to be setup ready to pair from the Homeassistant Addon.
I found this last step was a bit difficult (hit/miss) due timing. reset procedure etc.
For the lock to initially appear in the HA ADDon (first time) to be paired , I think it has to have been reset (ie free of any connection to previous pair bluetooth connections). So I think the Gateway Bluetooth Scan has to discover a ‘new’ lock. (New like fresh out of the box)
Once the Gateway finds a ‘new’ lock it will present in HA addon with a PAIR option. This is the first milestone . . but don’t be tempted to hit that HA Addon PAIR option yet! The lock must be put into pair mode just before you attempt the HA Addon PAIR operation.
So for me, once the lock appeared in HA Addon ready to be paired . . .
I touched the lock keypad, heard the speaker say ‘start Bluetooth Admin’, then quickly hit the HA Addon PAIR button. If successful the lock responds via speaker ’ was successful’ or similar.
Thanks for the tips. The lock I have is 5B01, it doesn’t have a keypad, just fobs, I haven’t worked out how to reset it, there are no obvious buttons.
I have never seen the lock appear in the addon. I wasn’t completely sure what was supposed to happen there as there are no screenshots of that process anywhere that I could find.
I did download the TTLOCK app, which will see the lock, although I didn’t pair it. If I can’t see how to reset the lock on the device, it will have to be paired and then reset with the app.