How-To Guides
...
Integration Guides
Azure IoT Hub Guides

Set up an Azure IoT Hub

3min

Azure IoT Hub integration enables Litmus Edge to publish data directly to the Microsoft Azure cloud. You will need to set up the Azure IoT Hub before setting up the connector in Litmus Edge.

Before you begin

You must have an Azure account.

Step 1: Create an IoT Hub

You can create the IoT Hub in the Microsoft Azure portal.

To create an IoT Hub:

  1. Log in with your Azure account.
  2. Click Create a resource. The Everything dialog box appears.
  3. Enter IoT Hub in the Search bar.

    Azure Everything dialog box
    Azure Everything dialog box
    
  4. Click IoT Hub, and then click Create.

    IoT Create button
    IoT Create button
    
  5. From the Basics tab, select an option from the Subscription drop-down list.
  6. Do one of the following:
    • Select an option from the Resource Group drop-down list.
    • Click Create new and create a new resource group.
  7. Select an option from the Region drop-down list.
  8. Enter a name for the IoT Hub in the IoT Hub Name field.
  9. Click the Size and scale tab.
  10. Select an option from the Pricing and scale tier drop-down list.
  11. Enter a value in the Number of S1 IoT Hub units field to determine the number of connected devices to host on Azure and send messages to and from Litmus Edge.
  12. Click the Review + Create tab to finalize creating the IoT Hub and begin adding devices.

Step 2: Add IoT Device to Hub

After creating the IoT Hub, you will need to add an IoT device to the hub.

To add an IoT device to the hub:

  1. From the Azure portal, open the Command-Line-Interface (CLI).

    Command-Line-Interface icon
    Command-Line-Interface icon
    
  2. In the Azure CLI, enter the following two commands. Make sure to replace with YourIotHubName and MyNodeDevice with the names of your respective IoT Hub and device. az extension add --name azure-iot az iot hub device-identity create --hub-name YourIoTHubName --device-id MyNodeDevice
  3. From the Azure portal, click your IoT Hub.
  4. Under Explorers, click IoT devices to verify that you successfully added the new device.