A Gentle Introduction to Netduino
- Posted: Jun 10, 2011 at 6:00 AM
- 18,739 Views
- 3 Comments
Loading User Information from Channel 9
Something went wrong getting user information from Channel 9
Loading User Information from MSDN
Something went wrong getting user information from MSDN
Loading Visual Studio Achievements
Something went wrong getting the Visual Studio Achievements
While I've been doing a good number Netduino posts (I'm currently try to do one hardware related post a week or so), but what if you're like me and haven't done much with circuit level hardware work before? (Last time I did anything even close was in the Army 25+ years ago... wow, that makes me feel old...lol)
What we need is some kind of targeted document to (re)introduce us to circuit level design and is also covers developing with one of our favorite .Net Dev hardware platforms, Netduino.
This “guide” started as pretty basic article and turned into a slightly more expanded guide on electronic design and programming techniques for Netduino. To knowledgeable users, some topics may seem gone too much in depth and detail even for “basic” subjects. However, the aim was to provide beginners with knowledge and confidence they need to become advanced enough so that to design successful microcontroller projects by themselves. Additionally, it is always a good idea to understand how things work, even when we can achieve the results using LEGO approach with shields.
The guide uses a build as you go approach, starting with as simple a project as possible and adding to it
Project One – Netduino can blink … a LED
Part I (electronic)
This is kind of a widely accepted “Hello world” project when matters come to Netduino. Why? Because on first glance it is very simple but there are few points that an absolute beginner may fall in and as a result can “burn” its Netduino. This would be too bad and we want to prevent it from happening, so here is how:
In this project we are going to use Netduino to power up and down (flash) a Light-Emitting Diode (LED). LEDs usually come in different shape, size and colour but basically what they do is to emit light (what a surprise .
Part II (programming)
It is time for some programming.
In first place, we need a development environment. There are tons of excellent step by step materials of how to install it so just grab one from Netduino web site and follow it. From now on, I will assume you have it done and the environment is installed and ready for “fight”. So, let’s write some code. Create a new project appropriate for your Netduino. I have N+ but this doesn’t make any difference as we won’t use anything specific to the type of Netduino, such as MicroSD or Network.
We are going to write a few simple examples, gradually increasing complexity, which will help you become use to some basics of the hardware, .NET Micro Framework and Netduino SDK.
FIRST EXAMPLE - BORING LED FLASHING
Crate a new Netduino project. In Main() method use following code:
Here's a snap of the included Visual Studio Solution, with the code for the above snip shown.
Now the guide, while an "introduction" may still be to deep and technical for anyone without any electronic or circuit design exposure or experience. If you have no clue what a resister is, or you think a breadboard is that thing tucked in over your utensil drawer, then this guide may be a level heavy for you.
If you've done a little electronic/circuit hardware before but have yet to take the Netduino plunge, this guide might just be perfect for you.
Here’s a few more links you might find interesting: