Today I started the amazing Intel Edison board to try and use the XMPP-IoT tools to connect it securely over internet and it worked like a charm.
inittial setup and configuring for wifi was done with the instructions from Intel, i used the mac version. It didn’t take long to get i hooked upp to wifi. Activate a password on root for it to enable remote ssh
Upgrade flash image to the latest
Get the software started
I am using a fork from the python SleekXMPP package. Just wget the SleekXMPP package with the XMPP-IoT extensions from my Github. Python 2.7.3 is already on the machine. The GPIO package ”mraa” for python is also installed from the beginning very handy.
You need two XMPP accounts on a server somewhere there are many https://xmpp.net/directory.php I usually use the swedish jabber.se. Create two accounts so they later can talk to each other.
in the /home/root folder on the Edison do:
wget --no-check-certificate https://github.com/joachimlindborg/SleekXMPP/archive/xep_0323_325.zip
Start off with blinking the magical led
Go down in the example katalog and start the python Edison example with your xmpp account.
python IoT_GPIODevice_Edison.py -j firstname.lastname@example.org -p password -n test_device
should look something like this
Now direct your browser to https://conversejs.org/# login with the other xmpp user you created. email@example.com. Then choose to add a contact and provide the first account it should just accept and you can start chat with the device. use ”hi”, ”toggle” ”relay=true” and ”?”
If you have a RELAY and a PIR sensor wire them up to the board use GPIO pin 13 for the relay and GPIO 8 for the PIR you can see the PIR sensor changing
Some more interesting articles
The journal logs keep filling up so I changed the journaling.conf
to restart a clean image but I failed totally the reflashed edison keeps all settings
I found dokumentation on the opkg package manager very useful, especially the command to remove a package with dependencies
opkg --force-removal-of-dependent-packages remove <<yourpackage>>
Examples on using GPIO with python on the Edison Aurduion board
Jumpers on the Edison board