Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / IoT

Intel® IoT Gateway Software Suite: Connecting to the Cloud

0.00/5 (No votes)
18 Aug 2017CPOL5 min read 6.7K  
This section contains steps to install cloud support on your gateway and is geared toward users working with Intel® IoT Gateway Software Suite

This article is for our sponsors at CodeProject. These articles are intended to provide you with information on products and services that we consider useful and of value to developers

Now that you've gotten your Hello, World! program running, you can start connecting your gateway to the cloud. The IoT cloud repository allows you to add support for multiple cloud platforms, such as Microsoft Azure*, Google Cloud Platform*, IBM Watson IoT* and Amazon Web Services (AWS)* to your Intel® IoT device. This section contains steps to install cloud support on your gateway.

This section is geared toward users working with Intel® IoT Gateway Software Suite.

For more information on the cloud platforms that Intel supports, see the official sites for the following:

Adding cloud support

  1. Load the IoT Gateway Developer Hub interface in your browser by entering the IP address of your gateway. The default username and password are both root.

    Tip: You can find your gateway’s IP address using the ifconfig command.

  2. Record the image version you have installed for use in later steps (for example, WR7.0.0.13):

  3. Next, you'll add the IoT cloud repository. Follow the steps to do so using the Developer Hub or the command line.

Installing cloud support using the Developer Hub

Go to the Administration section and launch the Cloud Commander web console. Log in with the username root and password root if requested.

  • Scroll to the bottom of the page and click the Console button in the bottom right of the window.

  • In the console, enter the following command:
    rpm --import http://iotdk.intel.com/misc/iot_pub2.key
  • Scroll to the top of the page and go to the Packages section. Click the Add Repo + button.

  • Populate the fields with the following information and click Add Repository:
    • Name: IoT_Cloud
    • URL: http://iotdk.intel.com/repos/iot-cloud/wrlinux7/rcplXX (where XX is the last 2 digits of the image version you recorded earlier, for example http://iotdk.intel.com/repos/iot-cloud/wrlinux7/rcpl13/
  • Finally, click the Update Repositories button to update the package list.

    Install packages for cloud platforms

    Click the Add Packages + button to bring up the list of packages you can install.

  • Search for cloud using the search box at the top of the package window to get a list of the supported cloud platforms.

  • Click the Install button on any of these packages to install support for the cloud platform for all available programming languages.

    Note: Packages can also be installed for a specific programming language individually, if desired.

Now that you've installed cloud support for your gateway, you can continue with the steps below to install sensor support for Node-RED*. Refer to the Next Steps section for steps on how to get started programming your board to connect to the cloud using Node-RED, C++, or any of the other supported programming languages.

Installing cloud support using the command line

  1. From the command line, run the following commands to add the repository (where XX is the last 2 digits of the image version you recorded earlier, for example http://iotdk.intel.com/repos/iot-cloud/wrlinux7/rcpl13/
  2. rpm --import http://iotdk.intel.com/misc/iot_pub2.key
    smart channel --add IoT_Cloud type=rpm-md name="IoT_Cloud" 
     baseurl=http://iotdk.intel.com/repos/iot-cloud/wrlinux7/rcplXX/
    smart update
  3. Run the following commands to install support for a given cloud platform:

    smart update
    smart install packagegroup-cloud-azure
    smart install packagegroup-cloud-google
    smart install packagegroup-cloud-ibm
    smart install packagegroup-cloud-aws

Now that you've installed cloud support for your gateway, you can continue with the steps below to install sensor support for Node-RED. Refer to the Next Steps section for steps on how to get started programming your board to connect to the cloud using Node-RED, C++, or any of the other supported programming languages.

Installing sensor support for Node-RED*

There is a package available in the cloud repository which installs nodes for a limited number of sensors. To install this package, follow the instructions below for your given platform.

Using the Developer Hub (Wind River*)

  1. Go to the Packages section and click Add Package +.
  2. Search for node-red-contrib-upm and click the Install button.
  3. Next, you'll restart the Node-RED service. In the Packages section, scroll down until you find the node-red-experience package.
  4. Click the Stop button twice to stop and start the service. Wait for a few seconds before re-launching Node-RED from the Administration section, where any newly installed nodes should now appear.

Using the command line (Wind River*)

  1. From the command line, run the following commands:

    smart update
    smart install node-red-contrib-upm
    systemctl restart node-red-experience

Troubleshooting

Node-RED* nodes don’t show after installing support for a cloud platform

The Node-RED service needs to be restarted to pick up new nodes. Follow the instructions below to restart the service using either the Developer Hub or the command line.

Using the Developer Hub (Wind River*)

In the Packages section, scroll down until you find the node-red-experience package. Click the Stop button twice to stop and start the service. Wait for a few seconds before re-launching Node-RED from the Administration section, where any newly installed nodes should now appear.

Using the command line (Wind River*)

If you are using the command line instead of the Developer Hub, run the following command to restart the Node-RED service:

systemctl restart node-red-experience

Next Steps

See the appropriate link below for details on enabling your gateway to connect to a cloud platform, based on your programming language of choice:

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)