Comments (8)
I have not seen this issue before on my side. Now I do know that once in a while an IKEA update just bricks my gateway and destroys all connections. Even connections with home assistent and Google Home. Also the app won't work unless I reboot the gateway and that will reset the identities.
So i'm not sure on this one.
from ikea-tradfri-coap-docs.
I have to reboot it after DHCP server reboots so the symbolic hostname works again. I did this both by powercycling and by
coap-client -m post -u "$TF_USERNAME" -k "$TF_PRESHARED_KEY" "coaps://$TF_GATEWAYIP:5684/15011/9030"
But for me, the identities stay in place and are not reset.
from ikea-tradfri-coap-docs.
Huh oke well that could maybe then be a defect in my unit 🤣.
Then I would suggest using a uuid as the identity and then create a script that will renew the key after 4 to 6 weeks.
I am however curious how many keys it will keep in storage then.
from ikea-tradfri-coap-docs.
I just realized I can do
coap-client -m post -u "Client_identity" -k "$TF_GATEWAYCODE" -e "{\"9090\":\"$TF_USERNAME\"}" "coaps://$TF_GATEWAYIP:5684/15011/9063"
with the old username after it expired. So I could just do it every time and ignore the
4.00
it returns if it's still valid and only store the PSK if it's returned.
from ikea-tradfri-coap-docs.
mmm Oke thats new since I know from testing way back that didn't work. But maybe they changed that in an update.
from ikea-tradfri-coap-docs.
Something like
TF_USERNAME=sonic
TF_GATEWAYCODE=0Aa000AaaAaaaAAA
TF_GATEWAYIP=GW-A0A0A0A000A0.
TF_PRESHARED_KEY=$(coap-client -m post -u "Client_identity" -k "$TF_GATEWAYCODE" -e "{\"9090\":\"$TF_USERNAME\"}" "coaps://$TF_GATEWAYIP:5684/15011/9063" | sed -n 2p | jq -r '."9091"')
if [ -z "$TF_PRESHARED_KEY" ]
then
TF_PRESHARED_KEY=$(cat /tmp/tradfri-PSK.txt)
else
echo $TF_PRESHARED_KEY >/tmp/tradfri-PSK.txt
fi
echo TF_PRESHARED_KEY=$TF_PRESHARED_KEY
I'll see in 6 weeks whether it works :-)
from ikea-tradfri-coap-docs.
Cool yeah if it works please create a pull request so it can be documented
from ikea-tradfri-coap-docs.
Oct 13 02:44:31 ALRT 20 invalidate peer
Oct 13 02:44:31 WARN received alert, peer has been invalidated
Damn, still doesn't work with 1.11.0047 ...
from ikea-tradfri-coap-docs.
Related Issues (20)
- Possible to get the Preshared Key? HOT 7
- Possible to get the Bulb Type? HOT 2
- Try RGB-Colors but failed HOT 9
- aws connection HOT 1
- Set motion sensor interval? HOT 7
- Transition Time is not a Float HOT 4
- Notification when status of light changes HOT 3
- Maximum for Blind-Float? HOT 1
- reboot returns 4.05 HOT 1
- Shortcut Button HOT 1
- Documentation for the DEVICE (3) key HOT 2
- lib-coap error on install on WIndows HOT 5
- Build with 4.3.0 final? HOT 1
- Another guide about IKEA Tradfri gateway communication HOT 1
- Possible Bug in RGB Bulb Firmware (v. 2.3.086) HOT 1
- Documentation for Air purifier HOT 1
- Scenes use clarification HOT 1
- Incorrect id on get group info endpoint HOT 2
- Wrong string interpolation of TF_USERNAME HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ikea-tradfri-coap-docs.