Quickstart: Install the Azure Sphere SDK for Windows

To start using an Azure Sphere dev kit on Windows, you need to set up the dev kit, install the SDK, and install any additional software required for your development environment.

Prerequisites

  • An Azure Sphere development kit
  • A PC running Windows Anniversary Update or later
  • An unused USB port and, if you're running a virtual machine, support for USB pass-through

Set up your dev kit on a Windows PC

Connect your Azure Sphere dev kit to your PC through USB. When plugged in, the device exposes four USB Serial Converters.

The first time you plug in the device, the drivers should be automatically downloaded and installed. Installation can be slow; if the drivers are not installed automatically, right-click the device name in Device Manager and select Update driver. Alternatively, you can download the drivers from Future Technology Devices International (FTDI). Choose the driver that matches your Windows installation (32- or 64-bit).

To verify installation, open Device Manager. Under Universal Serial Bus controllers, look for four USB Serial Converters. Device Manager with four USB serial converters

Note

If you've previously used this board and enabled RTApp development, you will see three converters instead of four. This is normal and does not represent an error.

If other errors occur, see Troubleshoot Azure Sphere issues for help.

Install the Azure Sphere SDK

  1. Download the SDK. Save the downloaded file on your PC.

  2. Run the downloaded .exe to install the SDK. Agree to the license terms, and then select Next.

  3. Select Install to begin installation.

  4. Accept the elevation prompt if one appears.

  5. When setup completes, restart your PC if the setup application requests it.

If the installer returns errors, try uninstalling and then reinstalling the SDK package.

The SDK includes libraries for application development and a custom Azure Sphere Developer Command Prompt, which is available in the Start menu under Azure Sphere. The custom prompt sets up the Windows command environment that is required to work with the azsphere command-line utility. Use this prompt any time you use the azsphere command.

The installer installs both the Azure Sphere CLI v1 and the Azure Sphere CLI v2 Beta versions of the CLI. You don't need to uninstall the current version because the installation will update any existing version. Azure Sphere CLI v1 is installed in C:\Program Files (x86)\Microsoft Azure Sphere SDK\Tools and Azure Sphere CLI v2 Beta is installed in C:\Program Files (x86)\Microsoft Azure Sphere SDK\Tools_v2. For more information on the beta version of the CLI, see Azure Sphere CLI v2 Beta.

Azure Sphere CLI v1 will continue to be available using the Azure Sphere Developer Command Prompt, which is available in the Start menu under Azure Sphere. You can now run Azure Sphere CLI v2 Beta with the azsphere command from either Windows Command Prompt or PowerShell. We recommend PowerShell as it offers tab completion features which is not available from Windows Command Prompt.

After installing the CLI for the first time, check that it's installed and you've got the correct version by running azsphere show-version.

Install Visual Studio and the Azure Sphere extension

You can use Visual Studio Enterprise, Professional, or Community 2019 version 16.4 or higher to develop Azure Sphere applications.

  1. If you haven't already done so, install Visual Studio.
  2. Go to the Visual Studio Marketplace to install the Visual Studio Extension for Azure Sphere.

The Azure Sphere SDK and the Azure Sphere Extension for Visual Studio include all the tools you need to develop Azure Sphere applications.

Install CMake and Ninja on Windows

If you plan to use Visual Studio Code or the Windows CLI, you need to install CMake and Ninja manually.

  1. To install CMake, download and install the appropriate version of CMake for your development environment from the CMake download page.

  2. Download Ninja. The download is a small zip file. To install Ninja, open the zip file, select Extract All, and note the file location of the extracted file ninja.exe.

  3. Add the CMake bin directory (typically, C:\Program Files\CMake\bin) and the directory containing ninja.exe to your PATH environment variable. To find information about setting this environment variable in Windows, type "path" in the Search box.

Install the Azure Sphere extension for Visual Studio Code

  1. Use the links in Download Visual Studio Code to install Visual Studio Code, if you haven't already done so.

  2. Install the Azure Sphere Extension from the Extension Marketplace, or in Visual Studio Code, search for Azure Sphere in the Extension Marketplace and install it.

  3. After installation, you should see Azure Sphere, C/C++, and CMake Tools extensions in the ENABLED Extensions pane in the Visual Studio Code IDE.

When installation is complete, the Readme page for the extension will open. The Readme page provides useful information about Visual Studio Code configuration and requirements, and is updated along with the extension. You can view the Readme page any time by opening the Extensions pane and selecting Azure Sphere.

Next steps