Tradfri 1.8.25 - offline - communication_error

Maybe I am missing something but I too am having issues with the Tradfri binding after the update. I have followed the suggestions in this thread and done the following:

  1. comment out Things file entries for Tradfri
  2. add gateway via inbox of PaperUI
  3. entered the code from gateway into Thing configuration
  4. restarted services
  5. expanded show more to retreive the identity and pre-shared key
    This is where things get messy. The pre-shared key is just **********.

Where can I get the actual key?

I have tried with just “” for key but it still isn’t working.

Thank you,
Jason…

Hi Jason,
you may get pre-shared key via rest interface:

http://<Your_IP>:8080/rest/things/tradfri:gateway:gwb07xxxxxxxxx

Use your IP/hostname with standard port 8080 and with your Tradfri gateway UID (taken from PaperUI).

Actually, I simply copied and pasted the ******** from the pre-shared key field in PaperUI into my Things file; it “magically” transformed from the series of dots into the plain ASCII sequence (which in my case is the code from the gateway anyway)

This was my solution.

I tried stopping OH, clearing tmp and cache, restarting gateway, starting OH. Gateway was not autodiscovered and “adding manually” security and pre-shared key got pre-filled.

I downloaded pip for python 3.5:
sudo curl -O https://bootstrap.pypa.io/get-pip.py
sudo python3.5 get-pip.py

installed pytradfri:
sudo pip3.5 install pytradfri

Ran:
python3 -i -m pytradfri (192.mygateway-IP)

Found a line:
DEBUG:pytradfri.api.libcoap_api:Executing myip post ['150XX', '90XX']: {'90XX': 'eff3079481a24f1f9b9f8XXXXXXXXXX'}

Typing eff3079481a24f1f9b9f8XXXXXXXXXX’ as identity got the Gateway online in no-time :facepunch::facepunch:

Today’s report. (not config file related, using paperUI only).

After stopping the bundle through the night, the gateway survived, but no remotes were updated when I checked this morning.
I then gathered my 9 remotes within 1m from the gateway, power cycled it and left for work.
(I also pulled the power on a HUE bridge 1m away ensuring it was not interfering on another channel).
Arriving home some 9hrs later, none of the remotes had received any update, all still pending.

Now, this is what did the trick. Remove and re-insert the battery on each remote.
Within 15-20min one by one (~15min each) they got updated until only 3 remained.

I measured the battery voltage on the ones that was still pending, and they were all just 2.9V. (they still controlled their lights OK)
After inserting fresh batteries (starting at 3.2V, but ended at 3.1/3.0 after being inserted in the remote), the 3 remaining ones was updated within 30min as well.
I then started the Ikea bundle and the Ikea items came Online at once, only to go Offline some minutes later.
I then power cycled the gateway (first power-cycle after it had updated the 9 remotes) and it looks good now after more than 1hr. Lets see what happens during the night…

Edit: still OK this morning …
Edit2: still OK in the evening.

This proves that coap communication during firmware update of remotes can kill the gateway.
I manage a second site with fever lamps and remotes, and the only thing I needed to do there was restart the bundle after the gateway updated and restarted. The new gateway firmware did not help with this issue. Still flaky.

1 Like

Final report.
The 1.8.25 firmware update totally wrecked my gateway connection.
After trying all in my previous post, I had to find a pin and reset the whole thing.
Took the opportunity to transfer the majority of my devices to my conbee/deconz setup, so after the hard reset, I now have only the gateway, one remote and one E27 CT bulb.

See here for more details.

What is the syntax for the things file if i want to separate Bridge and things?

Not sure what you mean…

Bridge tradfri:gateway:gwb8d7 [ host="192.168.192.69", identity="12d45", preSharedKey="7gaCh" ] {
    0830 Remote1 [ id=65536 ]
    0210 ColorBulb1  [ id=65537 ]    
    0220 Bulb1 "Office Window" @ "Office" [ id=65538 ]    
    0220 Bulb2 "Floor Lamp" @ "Livingroom" [ id=65539 ]   
    0220 Bulb3 "Oliver Window" @ "Oliver" [ id=65540 ]    
    0220 Bulb4 "Bench" @ "Bedroom" [ id=65541 ]    
}

This is a way to do it. but it i want to separate Bridge and things.

Bridge tradfri:gateway:gwb8d7 [ host="192.168.192.69", identity="12d45", preSharedKey="7gaCh" ] 
Thing tradfri:0830:gwb8d7:Remote1 [ id=65536 ]
}

Then i can have the bridge in PaperUi and things in file.

IC. I have only done it the other way around. Brigdes in things files and things in paperUI.
What is the advantage of having things in a things-file?

For me, the new firmware gave me zero crashes since installation (about 10 days).
Keep fingers crossed!

2 Likes

I can confirm that power cycling the remotes triggers the upgrade after they all got struck in pending state (and the gateway was unresponsive).

1 Like

I got the same problem. Every couple of days the connection drops. And cannot reastablish…

I had been happy for a long while till recently

Then the only salvation is The pin of re-pair…

That is what I keep doing but it is breaking the “peace of mind” of automation.
I liked to control my home when I am not at home.
In this current state… sighs

I got to delete the thing from PaperUI, refind the gateway re-use the key, then restart OH2 to force it to recognise that all lights can be connected to.

Ok, so you have re-paired all devices after hard-reset of the Gateway?

And you still see Gateway Offline situations that is not related to OH2 restarts?

If it is OH2 restart related this is a known issue that is still not resolved. More here.

If not, you might consider replacing the Ikea Gateway, or go the conbee/deconz route.

No. After losing connection. I delete the gateway and re-discover it, put the key. Then gateway is fine.
Restart to change all IKEA devices to online.

Are all devices done updating? There can be instability until all device updates are done.

1 Like

According to tradfri app all devices are up to date.

When connection is lost, Google home is still connected.

1 Like

Yesterday i have to unpower my Pi with Openhab. Tradfri don’t work afther boot and i try everyting in this Fred to resolve the problem. Nothing worked, as well not what i have sucessfully done last time. Long story short, i add all my Tradfri stuff over the Hue bridge now … I hope there will be a Fix in the future …

Thanks for all the Posts and efforts !