Control The Arduino Board With Windows 10 PC or Mobile

Introduction

In this article, I'll show you how to control the Arduino board with Windows 10 PC or Mobile using Windows Virtual Shield for Arduino. This app was developed by the Microsoft Corporation and you can get it from the Windows Store.


Requirements

Hardware
  • Arduino Uno
  • Bluetooth Module HC-05
  • Windows 10
  • Windows Virtual Shield for Arduino - Get the app 


Software
  • Arduino IDE 1.6 or better
  • ArduinoJson library
  • Arduino JSON library - GitHub
  • VS2015
The following sensors are used to control directly from Arduino Wiring,

Sensors
  • Accelerometer
  • Compass
  • Geolocator (GPS)
  • Gyrometer
  • Light Sensor
  • Orientation
Capabilities
  • Camera
  • Device info (name, date/time/timezone, os)
  • Email (initiation)
  • Microphone
  • Notifications (Tile/Toast)
  • Screen (Text, Images, Audio/Video, Rectangles, Buttons, Touchscreen)
  • Sms (initiation)
  • Speech to Text and Speech Recognition
  • can receive table data from previous web search
  • Vibration
  • Web (Get and Post with result parsing)
  • XPath
  • JSON
  • Simple text
  • Regular expressions
  • Table iteration (keys/values saved)
Connection
  • Setup the Arduino IDE 1.6 or better.

  • Get the Arduino JSON library (Click here) download the zip. and Add it to the Arduino | Sketch, then Include library, Add.Zip library.

  • In the Arduino IDE Sketch, Include library, then Manage Library, A library manager will open in that search box you can type windows virtual shield for Arduino and click install button the library will be added to the Arduino IDE.
Bluetooth
  • RX pin to TX
  • TX pin to RX
  • Vcc to 5v
  • Gnd to Gnd
Code: Hello Virtual Shield
  1. #include <ArduinoJson.h>    
  2. #include <VirtualShield.h>    
  3. #include <Text.h>    
  4.     
  5. VirtualShield shield;        // identify the shield    
  6. Text screen = Text(shield);  // connect the screen    
  7.    
  8. void setup()    
  9. {    
  10.     shield.begin(9600);              // begin communication    
  11.     
  12.     screen.clear();              // clear the screen    
  13.     screen.print("Hello \n my Virtual Shields for Arduino");       
  14. }   
Explanation

Add the libraries first i,e 
  1. #include <ArduinoJson.h>  
  2. #include <VirtualShield.h>  
  3. #include <Text.h>  
  • VirtualShield is like a function used to find the shield using BT communication.
  • The Text screen are used to connect the screen to display the text.
  • The setup() is one type of the built in function.
  • shield.begin() in your setup() is called as the baud rate and it is mainly used for the communication purpose.
  • screen.clear() clears the screen.
Output

Read more articles on Arduino:

Up Next
    Ebook Download
    View all
    Learn
    View all