Hello everybody,
I am a newbie whit Domoticz and i hope that i can control my home and garden whit Domoticz.
As a start i was trying to install the Ikea Tradfri plugin because i already have some Tradfri components, and thats a good start i thought .
So, i have a raspberry 3 clean install whit "Raspbian stretch 2018-06-28" and also a clean install of "Domoticz 4.9700"
After the install of Domoticz i tried to Install libcoap as per ggravlingen's description, only whit that script gave a error of missing some file's (it Couldn't find áutoconfig', 'aclocal', 'libtool', 'libtoolize')
(i dind't make a copy of these error's).
Whit some help of google i found at
https://learn.pimoroni.com/tutorial/san ... om-your-pi a working instruction for Coap, so first step dune.
Next i followed the instruction from the Github, it looks like everything was installed oké,
So, i configured IKEA Tradfri in Domoticz, and in the log there was the following error:
Code: Select all
2018-07-06 18:39:53.965 (Tradfri) Failed to connect to IKEA tradfri COAP-adapter! Status: 111 Description: Connection refused
2018-07-06 18:39:53.965 (Tradfri) Device has disconnected
I looked in some message's on this board and(re) installed/updated OpenSSL and twisted as suggested and also Run tradfri.tac whit Python3 and it display a error message after i pressed RUN
Code: Select all
Warning (from warnings module):
File "", line 0
UserWarning: You do not have a working installation of the service_identity module: 'No module named 'service_identity''.
Please install it from <https://pypi.python.org/pypi/service_identity> and make sure all of its dependencies are satisfied.
Without the service_identity module, Twisted can perform only rudimentary TLS client hostname verification.
Many valid certificate/hostname mappings may be rejected.
So i google-ed for service-identity and tried to install is whit " sudo pip install service_identity"
after re-run " sudo pip install service_identity " the commandline came whit the message that is is installed in Phyton2,7
only that don't get a solution probably because it is installed in Phyton 2,7 instead of 3,5, the next error display-ed in Phyton-3 after run tradfri.tac;
I don't know how to install the service-identyti in phyton3,5.
Code: Select all
Connected from IPv4Address(TCP, '127.0.0.1', 44672)
Data received: b'{"groups": "False", "identity": "***************", "pollinterval": "30", "psk": "{\\"9091\\":\\"****************\\",\\"9029\\":\\"1.4.0015\\"}", "gateway": "192.168.0.19", "action": "setConfig", "observe": "False"}'
Initializing gateway
Unhandled Error
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/usr/local/lib/python3.5/dist-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/usr/local/lib/python3.5/dist-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/usr/local/lib/python3.5/dist-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- <exception caught here> ---
File "/usr/local/lib/python3.5/dist-packages/twisted/internet/posixbase.py", line 614, in _doReadOrWrite
why = selectable.doRead()
File "/usr/local/lib/python3.5/dist-packages/twisted/internet/tcp.py", line 205, in doRead
return self._dataReceived(data)
File "/usr/local/lib/python3.5/dist-packages/twisted/internet/tcp.py", line 211, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/pi/domoticz/plugins/IKEA-Tradfri/tradfri.tac", line 76, in dataReceived
self.factory.initGateway(self, command)
File "/home/pi/domoticz/plugins/IKEA-Tradfri/tradfri.tac", line 275, in initGateway
self.devices = self.api(self.api(self.gateway.get_devices()))
File "/home/pi/.local/lib/python3.5/site-packages/pytradfri/api/libcoap_api.py", line 96, in request
return self._execute(api_commands, timeout=timeout)
File "/home/pi/.local/lib/python3.5/site-packages/pytradfri/api/libcoap_api.py", line 85, in _execute
raise RequestTimeout() from None
pytradfri.error.RequestTimeout:
Disconnected
(the ******** is because i removed the official code)
in the log of Domoticz the following message's show up;
Code: Select all
2018-07-06 19:07:24.279 (Tradfri) Connected successfully to: 192.168.0.19
2018-07-06 19:07:35.202 PluginSystem: Restarting I/O service thread.
2018-07-06 19:07:35.203 (Tradfri) Device has disconnected
Also the tradfri hub is not working when i run tradfri.tac (probably because the error) , after stop tradfri.tac it the HUB is working again.
I hope some of you can help me whit this problem.
Again, i have a new raspbian en domoticz install and only configured the IKEA Tradfri plugin.