Blog Post

Internet of Things Blog
2 MIN READ

Developer experience with Azure Sphere

OlivierBloch's avatar
OlivierBloch
Icon for Microsoft rankMicrosoft
Dec 12, 2019

Microsoft Azure Sphere is a secured, high-level application platform for internet-connected devices. And it is going GA in February 2020!

Azure Sphere is designed around around the 7 principles of highly secured devices and when learning more about these you will realize that the developer has a big role to play in securing IoT devices.

What is the developer experience like when working with Azure Sphere? What's new or different that you need to learn as an application developer? The good news is the experience is identical to writing any other application in Visual Studio.

Before we take a look at what the developer experience looks like for Azure Sphere, let’s review some fundamentals.

 

Azure Sphere overview

Think of Azure Sphere as being three things:

  1. Silicon with IP that provides a hardware root of trust and other security elements
  2. On top of that there is custom, secure Linux kernel
  3. And there is the Azure Sphere security service that provides device authentication and attestation as well as operating system and application updates

You can use Azure Sphere in two scenarios:

  1. Azure Sphere can be embedded into a new device (greenfield)
  2. An Azure Sphere device can act as a guardian module for currently installed, legacy devices (brownfield) that you don’t want to connect to the internet for security reasons or just can't because of limited networking capabilities, but that are producing interesting telemetry data that you would like to analyze.

 

Getting started

Azure Sphere is about IoT hardware so the first step is to pick your hardware. One choice is the Azure Sphere MT3620 Development Kit from Seeed.

Visual Studio 2019 is the IDE you will need to get started along with the Azure Sphere SDK onto your device.

One thing that will differ from what you might be familiar with is the fact that before you can start coding anything you will need to

  • create a tenant on the Azure Sphere security service
  • claim your device into this tenant to ensure only you can push code to it and have full control over it
  • Enable development on the device
  • Create the app manifest: on Azure Sphere, each application only has access to the hardware resource it needs, and developers need to create an app manifest that indicates to the secure OS which HW resources the app will be using

Once you have done these, you can go ahead and start blinking the LEDs - as we all know blinky is the Hello World for IoT. Writing, deploying, debugging your application will be the same experience as any other application developed in Visual Studio.

 

See the developer experience demo live

Watch Mike Hall, Principal Software Engineering lead for Azure Sphere, step through both a blinky application and a guardian module application on the #IoTShow.

 

To get started yourself, it's this way.

Feel free to share your impressions and comments below with your fellow IoT developers!

Published Dec 12, 2019
Version 1.0
  • Ghassan Hariz's avatar
    Ghassan Hariz
    Copper Contributor

    Lessons learned using the Azure Sphere Starter Kit from Avnet:

     

    • Update to the latest OS version ASAP. I faced some issues where the board could not connect to the service before I upgraded to OS version 19.10
    • I did face an issue where LPS22HH sensor was not found. However, after contacting Avnet through the element14 community, they promptly released a fix on Github.
    • Some of the Azure Sphere videos talk about configuring the IoT Hub settings by selecting the project in Visual Studio, selecting Overview and then choosing Connected Services, then clicking on IoT Hub. That never worked. After researching the issue, I found out that this method has been deprecated. In the new OS versions, the IoT Hub settings are all done in the app_manifest.json file. 
    • Detailed steps for connecting the Avnet Starter Kit to Azure IoT Hub can be found on my blog post and an overview of Azure Sphere can be found on LinkedIn.