Redirecting you to Developer Center... Click here if you are not automatically redirected.
- Windows Virtual Shields for Arduino
Set Up Windows Virtual Shields for Arduino
Get an Arduino and a Windows 10 device ready to use with Windows Virtual Shields for Arduino.
If you’ve used an Arduino
, you’re familiar with the concept of a shield. Each shield has a specialized purpose (e.g. a temperature shield, an accelerometer shield), and building a device with multiple shields can be complex, costly, and space-inefficient. Now imagine that you can use a low-cost Windows Lumia Phone as a compact set of shields. Your Arduino sketch would be able to access hundreds of dollars worth of sensors and capabilities in your Windows Phone through easy-to-use library calls.
This is exactly what the Windows Virtual Shields for Arduino library enables for developers. And that’s not the best part - this technology works on all Windows 10 devices, so you can use the sensors and capabilities on your PC or Surface as well. Also, the Arduino can offload computationally expensive tasks like speech recognition and web parsing to the Windows 10 companion device!
Let's learn how to setup hardware and software to work with Windows Virtual Shields for Arduino.
1. Get your Windows 10 device ready for developing projects using Windows Virtual Shields for Arduino. Hide
In this section of the tutorial, you'll prepare a Windows 10 device of your choice by loading it with the Windows Virtual Shields for Arduino application - this Universal Windows Application allows you to use your device as a "virtual shield" for an Arduino board. This results in some powerful possibilities for Makers, allowing them to utilize voice recognition, touch screens, and the computational power of Windows with relative ease.
The Windows Virtual Shields for Arduino application can run on any Windows 10 device, but this tutorial will explain setup with a Windows Phone.
What you need
Windows Phone running Windows 10 - we recommend the Lumia 520 or Lumia 635 .
Set up your Windows Phone
If your phone is not already running Windows 10, there are options to install preview versions of the software. Windows Phone 8 users can go to the Microsoft Store app to download the "Windows Insider" application - this app allows the user to opt into receiving Windows 10 Technical Previews as updates. Follow the prompts and instructions upon opening the app, and continue to the next step once your phone is successfully running Windows 10.
Option 1: Download the app from the Microsoft Store
Follow this link to the Microsoft Store page for Windows Virtual Shields for Arduino, download the application, and then install. You can then open the application to ensure it runs properly. Your device is now setup to be used as a "virtual shield" for an Arduino! You can proceed to the next page.
Option 2: Sideload the app using a PC and Visual Studio
What you need
- Visual Studio 2015 to sideload the Windows Virtual Shields for Arduino app onto a developer-unlocked phone.
- This repository containing the code for the Windows Virtual Shields for Arduino application. Either clone the repository or download it as a ZIP on your local disk. If you're not familiar with git and want to do a proper clone, follow the instructions here.
Set up Visual Studio 2015
- Install Visual Studio 2015 with the Windows 10 Developer Preview tools from dev.windows.com. We recommend the free Community Version of Visual Studio, but both Enterprise and Professional will work as well. If you already have Visual Studio installed, skip to the next step.
- In Visual Studio, load the Shield.sln from the repository downloaded in the "What you need" section above.
- Ensure your Windows 10 device (in this case a Windows Phone) is developer-unlocked. This page explains how to unlock Windows Phone 8.1, 8, and 7.1; however, the steps are the same for Windows 10 phones).
- Plug your Windows 10 device into your computer and deploy the Shield.sln program to your device. To do this, deploy to a "Local Machine", and be sure to set the architecture of the device as "ARM".
- Run the newly-installed Windows Virtual Shields for Arduino application on your phone to ensure the deploy was successful. Your Windows 10 device is now setup to be used as a virtual shield!
2. Set up your Arduino to use the Windows Virtual Shields for Arduino library Show
3. Write your first app: Hello, Blinky! Show