Setting Up Visual Studio and Visual Micro for Coding the Arduino.

by KurtRoesener in Circuits > Software

4323 Views, 41 Favorites, 0 Comments

Setting Up Visual Studio and Visual Micro for Coding the Arduino.

VS 2015 C++.JPG

In this Instructable I will explain how to setup, Visual Studio 2015 Community Edition and Visual Micro, the plug-in that allows users to code INO files like a Professional.

The Visual Micro plugin allows for greater control over your sketches.

This is from the main page, "IDE features such as:- see/edit library sources, jump to code definition, jump to compiler error, class explorer, intellisense, remembers board and Arduino version per project, code completion and a super fast compiler make learning and programming Arduino faster and easier."

First, we need to download VS 2015 Community, you can get it here:

https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx

Be sure to choose the left most option button. Now for Setup of VS 2015 Community, This is an Important note from the Visual Micro Site: Visual Micro requires C++ to be installed as a Visual Studio language. If you did not activate C++ when you installed Visual Studio, click "Download" and follow the instructions on that page to add C++ to your Visual Studio installation.

All three of the C++ options need to be checked off for the Visual Micro plugin to work correctly!
During this is install, it will take a while, you can download the plugin, from here:
http://www.visualmicro.com/page/Arduino-Visual-Studio-Downloads.aspx
The default options for this install are be fine.

Visual Studio 2015 Community - Setup

Screenshot 2015-10-24 18.58.34_cr.png
Screenshot 2015-10-24 19.03.15_cr.png
Screenshot 2015-10-24 19.04.31_cr.png

Once you have that installed you are ready to setup VS 2015.
The first thing I did was Turn Off Tutorial mode, if you leave it on, and sometimes you might want to, it creates 'Breakpoints' in your sketch. Picture 1
All you need to do is 'uncheck' it under the Visual Micro menu option.

Next you will want to make sure you have the 'Micro' tool-bars loaded, they look like Picture 2


If you don't have this, you'll need to 'Right-Click' some place on the existing Menu bar and make sure all 4 of the 'Micro' ones are 'Checked' Picture 3

Visual Micro - Opening an Example - Blink

Screenshot 2015-10-24 18.55.33.png
VS_blink_Solution.JPG
Screenshot 2015-10-24 19.03.15_cr2.png
Screenshot 2015-10-24 19.03.15_cr.png

Now on to opening a new sketch, when you either select the menu option FILE>NEW>ARDUINO PROJECT or Click on the NEW button then the TEMPLATES>VISUAL C++>VISUAL MICRO, you will presented with Picture 1

This allows for 2 options, one is a Blank Sketch and the other is a Blink sketch. I choose a Blink sketch for this Demo. On the Right hand side of VS 2015 you should see something similar to Picture 2.

If Solution Explorer isn't selected you will need to click on the tab at the bottom to select it. Then select the Blink.ino file, it should now display in the main window, Picture 3.

At this point it is Important to note that you want to select "Release" just to the left of "x86" at the very top, middle, in Picture 4


That is a brief Tutorial on how to setup these tools for a coding experience that is lacking in the Arduino IDE.

Please note, these setup instructions assume that you already have either the Arduino.cc or Arduino.org IDE installed.