Search code examples
meteorserverdigital-oceaniotcylon.js

Control Raspberry Pi or Arduino Remotely using a remote server (IoT)


I basically want to be able to access a webpage/web app from any computer to control a servo or read temperatures from temperature sensors connected to an Arduino or Raspberry Pi (doesn't matter to me I have both) that is remotely connected to the internet.

I would probably use Meteor.js for the webapp because I am familiar with it and can use Mongo to store data like temperature readings from the Arduino. I came across Cylon.js, but there is no documentation on hosting it on a remote server.

I don't want to use the Raspberry Pi or my own computer as a server, I want something more reliable like Digital Ocean or something.

Can anyone please point me in the right direction?


Solution

  • This is an ideal use-case of remote monitoring. This is how you can implement this in a reliable way:

    • Send temperature reading from the Pi to cloud (Azure IoT Hub)
    • Build your website and connect to IoT Hub from your website. Once done, host this website online (Azure Web Apps)

    You're done!

    Resources: Connecting to IoT Hub: https://azure.microsoft.com/en-us/develop/iot/get-started/ , https://github.com/Azure/azure-iot-sdks

    Deploying website: https://azure.microsoft.com/en-in/documentation/articles/web-sites-deploy/

    Azure free trial: https://azure.microsoft.com/en-us/free/

    Note that IoT Hub can store data for a maximum of 7 days (as of today). If you wish to use persistent storage, use either your own service/event processor or Stream Analytics (managed service) to store the data in persistent storage. IoT Hub can also help in cloud-to-device messaging if you wish to do so.