LIQUIDATION SALE! FREE Shipping on orders over $49 USA $99 INTERNATIONAL USE CODE: "LIQUIDATION" for 50% OF

Remote Access

Remote Access

Hey guys Matt here from MKSmartHouse.com and in this video I am going to show you how to setup the openhab cloud connector for remote access.
So what exactly are we going to accomplish in this video? Well, we are going to setup the openhab cloud connector which connects our openhab 2 server to the openhab servers at myopenhab.org. This allows us to remotely control our home automation devices. For example after we do this you can turn on a switch at home from anywhere in the world as long as you have an internet connection. Also, this allows for push notifications to mobile devices. So, when we set up access to the automation server from mobile, which is the next video, we will be able to receive notifications such as the sprinklers are on or the door is open.
 
1. First thing we have to do is access the web user interface and go to paper ui.
 
2. Then go to the addons tab in the left column. In the top navigation bar go to misc.
3. Find the openHAB cloud connector and press install.
4. Once it is installed in the left column navigation go to configuration and then the services sub tab. In the openHAB Cloud box click configure.
 
5. In the mode field click the drop down and select Notifications and Remote Access.
 
6. In the base URL Field type in https://myopenhab.org/ and click save.
 
7. Now go to this URL https://myopenhab.org/login Type in an email address and password of your choosing, this will be known as the admin myopenhab account.
 
8. You may notice there are two other fields the UUID Field and the secret field, so lets go get them. Open up your ssh client, on mac open terminal and on windows open up putty then ssh in.
9. Type in sudo nano /var/lib/openhab2/uuid and press enter.
 
10. It should open up a text file, this is the UUID so copy it and then paste it into the UUID field.
 
11. Then go back to the ssh window and press control x to exit the text document.
 
12. Now we are going to get the secret, so type in sudo nano /var/lib/openhab2/openhabcloud/secret and copy the text from the text file and paste it into the secret field in the web browser.
 
13. Then accept the terms of use and privacy policy and click register.
 
14. Once you are all registered on the webpage it might say offline in the top right. So go back to the ssh window and type in sudo reboot and press enter. The raspberry pi should now reboot.
 
15. Once it is booted back up refresh the myopenhab.org webpage and it should now say online.
 
Great, now it is all connected together so let’s go through all of myopenhab.org and show you all of its tabs. First up on the home page you should see text that says “Click here to access your openHAB’s dashboard” click it and you will now see your normal Web User interfaces as if you were at home which is good because now we could be a million miles away and still be able to access it. But, let’s go back to myopenhab so click the back arrow in your web browser. Now go to the items tab this tab will show the items that we allow external services to use, in the future we will connect IFTT and will use this feature more but for now it will be empty. The next tab is the event log and this shows all the different events that happen such as the system going on and offline. The notifications tab shows all the notifications that were sent out. When we click on the online tab it just takes us back to the event log. Then click on your accounts email and it will bring up some sub tabs. The first sub tab is account and in here we can change the UUID and secret myopenhab has access to, as well as change the password for the account. There are also two red buttons on the bottom which I do not recommend pressing. After that there is the devices sub tab and this just shows the devices that were logged in with this account and since we didn’t log into any there is nothing here. The next sub tab is Applications and this shows the applications that we approve to access our myopenhab account such as iftt in the future. The last sub tab and the last thing in myopenhab is users. This in my opinion is the most important tab because it is how the people who will be accessing your home automation server get there credentials to log in and the server can send unique messages. I recommend creating user accounts for everyone who will be accessing the automation server and it features so that way you can send them unique messages. For example, you can have the automation server send you a different wake up notification than someone else.
 
16. So let's go through and create more users, click add new user. Then type in the user’s email and password two times as well as choose the user type, I suggest making all users besides the admin regular users, then press add user. Repeat those steps for every user you want.
 
That’s it our openHAB automation server is now fully accessible outside of our home network and ready to be accessed from our mobile devices which is what the next video will cover. Alright thank you for watching and If you have any questions leave them in the comments section below or head over to mksmarthouse.com/forum where you have a better chance of it getting answered. Good Bye!