Remove the contents of your “tradfri.things” (or comment the lines in it, or move the file to somewhere else).
Restart openhab
After started, go into PaperUi to your inbox and accept the gateway.
Go to Configuration->Things and edit the Gateway, set the security code from the back of your gateway device.
Now OH talk to the gateway and recieve the identity.
Go edit the Gateway under Configuration->Things again.
Expand “Show more”, copy the value under Identity.
Go to your Tradfri.things and change it to look as:
Bridge tradfri:gateway:gw<your_gatewayMacAdr> [ host="", identity="<the identity value found in step 7>", preSharedKey="" ] {
Save the tradfri.things file, and then update your items to follow the new Bridge naming standard from step 8.
Same issue here. After applying the workaround I’m back to getting CoAP onError again after a few minutes I imagine this could be due to the PSK needing renegotiation? I’m using file-based config.
Kind of wish I could roll back the upgrade - out of all the home automation systems I’m using, Trådfri has been by far the most stable and painless!
Just in case anyone else is as detail oriented as I apparently am: the procedure in post #20 by @Johan_S works, but doing so throws a warning in the logs cannot add "BridgeImpl" with key "tradfri:gateway:gwa0c9a0xxxxxxxx". It exists already from provider "ManagedThingProvider"! Failed to add a second with the same UID from provider "GenericThingProvider"!
However, it all works nevertheless.
I was trying to make this warning go away, but did not succeed. The identity code changes every time the bridge is added to OH2 and hence, it seems impossible to add through text files only.
As a side node, if one tries to add it through the text files only with an invalid identity code, it seems to also knock out the TP-Link binding; all of my TP-LINK outlets became unreachable until I fixed the tradfri bridge.
Still not working for me.
Reports the current state, but won’t allow me to change it. I can see my lights are on, but I can’t turn them off!
Update
After a few minutes, it started working, but with a delay.
However, if I reboot again, I have to go through the whole process of removing the gw commenting out my things, re add the gw etc.
Let’s hope I don’t have to reboot again for a while!
@Thedannymullen curious…I have performed the following operation three or four times
delete bridge def from text file, restart OH2
discover and add bridge through PaperUI;
copy out Identity code and delete thing in PaperUI (mostly using the delete function in PaperUI, but once I simply deleted the whole jsonDB and its backups to see if that makes a difference)
add newly received identity code in text file for bridge definition
OH2 tries to add bridge Thing as now defined in text file, but status is stuck somewhere around “uninitialized”
In every single iteration of the above, I received a different value for the token identity…
I had similar issues before when the power went down, there is an extra thread for this. My workaround there was to change the gateway ip in habmin to something wrong, then back again to the correct value. This helped here, too.
@Thedannymullen thanks much
This is looks exactly like what I have (except, my values for the preSharedKey and identity and are much longer) and I believe was posted earlier by @Johan_S in post#20 in step8 unless I am missing something. Still for me the effects as I described above remain.