Great post, it was very easy to follow and all works great however the terminal does not.
All I see is
Any ideas ?
PS a warning at the start about oupgrade resetting previous configurations would be handy.
Apologies, I know this is an old thread but I have followed Paul Cousins instructions too and also have the "Connection refused" Error. I have tried to check that I have put the certificates over in a couple of different ways but as I am downloading them from Amazon to a mac and then uploading them to the onion, I'm not sure how I could be disturbing them.
I have looked for others having this problem and I don't see anyone so I'm really confused to know what I might be doing wrong.
Any chance you can say any more about why reinstalling the certificates worked for you?
Starting to think it might be an aws iot code issue. This is trying to set up a new device, and using their setup script. It at least starts to work, because on the aws monitor dashboard I see connections. This is the output it gives. I am posting this on their sdk issues too https://github.com/aws/aws-iot-device-sdk-python/issues/85
Running pub/sub sample application...
2017-11-01 05:13:53,808 - AWSIoTPythonSDK.core.protocol.internal.clients - DEBUG - Initializing MQTT layer...
2017-11-01 05:13:53,817 - AWSIoTPythonSDK.core.protocol.internal.clients - DEBUG - Registering internal event callbacks to MQTT layer...
2017-11-01 05:13:53,822 - AWSIoTPythonSDK.core.protocol.internal.workers - DEBUG - Event consuming thread started
2017-11-01 05:13:53,825 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - MqttCore initialized
2017-11-01 05:13:53,828 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Client id: basicPubSub
2017-11-01 05:13:53,832 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Protocol version: MQTTv3.1.1
2017-11-01 05:13:53,834 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Authentication type: TLSv1.2 certificate based Mutual Auth.
2017-11-01 05:13:53,838 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring endpoint...
2017-11-01 05:13:53,842 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring certificates...
2017-11-01 05:13:53,845 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring reconnect back off timing...
2017-11-01 05:13:53,848 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Base quiet time: 1.000000 sec
2017-11-01 05:13:53,852 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Max quiet time: 32.000000 sec
2017-11-01 05:13:53,855 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Stable connection time: 20.000000 sec
2017-11-01 05:13:53,859 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring offline requests queueing: max queue size: -1
2017-11-01 05:13:53,864 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring offline requests queue draining interval: 0.500000 sec
2017-11-01 05:13:53,869 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring connect/disconnect time out: 10.000000 sec
2017-11-01 05:13:53,873 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Configuring MQTT operation time out: 5.000000 sec
2017-11-01 05:13:53,876 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Performing sync connect...
2017-11-01 05:13:53,879 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Performing async connect...
2017-11-01 05:13:53,883 - AWSIoTPythonSDK.core.protocol.mqtt_core - INFO - Keep-alive: 30.000000 sec
2017-11-01 05:13:53,886 - AWSIoTPythonSDK.core.protocol.mqtt_core - DEBUG - Passing in general notification callbacks to internal client...
2017-11-01 05:13:53,890 - AWSIoTPythonSDK.core.protocol.internal.clients - DEBUG - Filling in fixed event callbacks: CONNACK, DISCONNECT, MESSAGE
Traceback (most recent call last):
File "aws-iot-device-sdk-python/samples/basicPubSub/basicPubSub.py", line 89, in <module>
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/MQTTLib.py", line 408, in connect
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/mqtt_core.py", line 168, in connect
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/mqtt_core.py", line 179, in connect_async
rc = self._internal_async_client.connect(keep_alive_sec, ack_callback)
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/internal/clients.py", line 113, in connect
rc = self._paho_client.connect(host, port, keep_alive_sec)
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/paho/client.py", line 654, in connect
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/paho/client.py", line 797, in reconnect
File "/usr/lib/python2.7/ssl.py", line 943, in wrap_socket
File "/usr/lib/python2.7/ssl.py", line 552, in init
ssl.SSLError: unknown error (_ssl.c:2947)
Exception in thread Thread-1 (most likely raised during interpreter shutdown):
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
File "/usr/lib/python2.7/threading.py", line 754, in run
File "/usr/lib/python2.7/site-packages/AWSIoTPythonSDK/core/protocol/internal/workers.py", line 137, in _dispatch
File "/usr/lib/python2.7/threading.py", line 289, in exit
File "/usr/lib/python2.7/threading.py", line 216, in exit
File "/usr/lib/python2.7/threading.py", line 203, in release
<type 'exceptions.TypeError'>: 'NoneType' object is not callable
According to your post it is possible to install the home automation software Domoticz on the Omega2 by getting access to the genuine LEDE repos. I altered the /etc/opkg/distfeeds.conf accordingly, rebooted and updated OPKG. Packages were downloaded. But after the install command, I get the message Unknown package 'domoticz". I searched this community and the internet for solutions, but found nothing. Could it be that the Domoticz package is removed from the LEDE repo? Is there any way you can help me out?
@Tom-Strutt , without killing your enthusiasm for IOT I propose you to work with a alternative product in parallel. IOT has a really big spectrum of activities.
But the Omegas are nice smal and also quite limited in memory space, connectivity and OS'es.
Even if I don't have RaspberryPy i would encourage you to use such a device in parallel. With all the well organized info's you can find you will have a smoother start in to IOT.
The possibilities to connect are bigger (at least RPI 3) and there is a much larger range of OS'es you can run on it. Even a display you can use.
As you already have a omega2 you could try to adapt some of the RPI tutorials for your small device without loose pleasure for exploring the IOT world.
Sounds interesting, but what makes this platform any better than the major competitors, Brillo/Weave, IOT Eclipse, Apple HomeKit, etc, which have nearly unlimited resources and a reputation. I understand that you have built something for the onion, but it wouldnt be that difficult to duplicate for another platform.
I already hate this Win10 idea... but to each his own I guess. That being said, it looks like Microsoft developed some 'core' code for several devices so they can be accessed from a Windows 10 computer. I haven't gone further into their documentation. If the MS 'core' takes over the whole device, then it's an actual kernel, and that is very limiting IMO. I'm definitely not interested by that! However, if the MS 'core' can be one of the OpenWrt processes, then that can actually be useful.
Microsoft being Microsoft, and vulnerabilities found in their code on a much too regular basis, do we really need our garage door hacked by thieves, or a ransomware criminal asking for bitcoins to give us back the control to the house thermostat? And what about the coffeemaker?
if I am on my motorcycle and come home, I want the door to open automatically (if the radius is possible).
I see where you are going with this, a Bat Cave Garage Door. ;-) It certainly is possible. Anything that will try to automatically connect to your main controler via WiFi or blutooth (with proper security signature) will do to alert it.
About the open/close state of the door, maybe your system already has a light that you could use. If not, the simplest and cheapest way is to use a magnet switch (magnet on the door + glass fuse-like switch on the door frame).