Difficulty: intermediate
Estimated Time: 10 minutes

Welcome to the Azure IoT Edge Dev Tool Introduction Course. In this course, we'll learn the high-level Azure IoT Edge concepts and learn how to use the Azure IoT Edge Dev Tool.

The Azure IoT Edge addresses two main scenarios:

  1. Gateway: Enables non internet connected devices to send their data to Azure.
  2. Intelligence: Enables local storage, compute and real-time decision making on the edge of your network.

If you are new to Azure IoT Edge, then you should read through the Azure IoT Edge Concepts. In a nutshell, the Azure IoT Edge runtime is based on containers. The runtime itself is a container called EdgeAgent. Microsoft also provides a container called EdgeHub that sends messages from the IoT Edge device to your IoT Hub. You, the developer, create custom modules, package them into containers and deploy them to the IoT Edge device via the IoT Hub. One of the biggest benefits of using the IoT Edge Runtime, is that you can remotely deploy new modules, adjust properties, and even call methods on the IoT Edge Device.

The Azure IoT Edge Dev Tool assists developers in creating IoT Edge Solutions, coding and deploying modules and creating CI/CD pipelines. This CLI tool complements the IoT Edge VS Code extension by turning multi-step manual processes into simple one-line commands, such as iotedgedev modules --build --deploy, which performs all of the following for each module: dotnet restore, build, publish, docker build, tag, push and then deploys the configuration to the IoT Edge device. You can find all of the details on Azure IoT Edge Dev Tool here.

The follow diagram illustrates the IoT Edge concepts. EdgeAgent manages the Azure IoT Edge Runtime, EdgeHub sends messages to IoT Hub, and you create custom modules, properties, and routes which are deployed to the IoT Edge Device via the IoT Hub.

Azure IoT Edge Architecture

In this tutorial, we are going to introduce you to the Azure IoT Edge Dev Tool so you can see how the tool works without having to install anything on your computer. The solution we are going to build consists of a simulated temperature sensor module that will generate random data and a filter module which filters messages before sending them to IoT Hub.

Azure IoT Edge Architecture

We'll now install the Edge Dev Tool, create an IoT Edge Solution, retrieve our IoT Hub and Device connection strings, build our modules, deploy configuration, setup and start the IoT Edge Runtime and finally view the messages flowing into IoT Hub.

Let's get started!

Jon Gallant

In this tutorial you learned about Azure IoT Edge and the Azure IoT Edge Dev Tool.

The Azure IoT Edge Dev Tool has many more features to assist in your day-to-day IoT Edge development activities. You can also use all of these same commands in your CI/CD pipeline.

Please visit http://aka.ms/iotedgedev for the complete Azure IoT Edge Dev Tool documentation.

Don’t stop now! The next scenario will only take about 10 minutes to complete.

Azure IoT Edge Dev Tool Introduction

Step 1 of 5

Step 1 - Run Azure IoT Edge Dev Tool Container

To get started, let's run a custom Azure IoT Edge Dev Container that contains all of the pre-requisites required for IoT Edge development, including:

  • Docker
  • .NET Core SDK
  • Python
  • Pip
  • Azure CLI.

Click on the command below to run the jongallant/iotedgedev container, which will run the command in the terminal to the right.

When you see the following message printed in the terminal the container has been downloaded and you are safe to click the docker run command below. Status: Downloaded newer image for jongallant/iotedgedev:latest

docker run -it -v /var/run/docker.sock:/var/run/docker.sock -v /root:/root -w /root jongallant/iotedgedev

This container also includes the Azure IoT Edge Dev Tool, which was installed via pip with the following command:

pip install -U azure-iot-edge-dev-tool

(You do not need to execute this command because it is already included in the container)

Click Continue