Welcome to Scribd. Sign in or start your free trial to enjoy unlimited e-books, audiobooks & documents.Find out more
Download
Standard view
Full view
of .
Look up keyword
Like this
4Activity
0 of .
Results for:
No results containing your search query
P. 1
Robot Magazine Quadcopter.doc

Robot Magazine Quadcopter.doc

Ratings: (0)|Views: 163|Likes:
Published by Moez Sayani
Uploaded from Google Docs
Uploaded from Google Docs

More info:

Published by: Moez Sayani on Aug 04, 2012
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less

03/15/2013

pdf

text

original

 
Introduction to Programming Arduino Robots
Roger Tang, Moez Janmohammad, Dick Swan This article is the first of a multi-part series. It provides a great introduction toprogramming Arduino robot controllers. The series of articles is about an independentstudy course for two advanced high school students who are learning aboutindependent programming. Their ultimate objective is to build add intelligent controlfunctionality to a quadcopter robot. Because of the high popularity and ease of use of the Arduino controller, it was the logical choice to use for this activity.
Independent Studies Senior Project
 The Frisco School District in Texas offers an independent studies course for their moreadvanced high school seniors. Each student needs to find a professional advisor /mentor to help them define and accomplish a significant project. Our project is by farthe coolest project in this year’s group and the only one dealing with robots andembedded programming. We – Roger and Moez – are working together as a team andfound Dick as our advisor.Our overall objective is to build a small robotic quadcopter (i.e. a helicopter with fourseparate blades/motors). The quadcopter has an embedded controller programmedusing available open source control software. The project will add functionality bybuilding a custom designed remote control communicating over standard Wi-Fi withnew innovative user interface capabilities. The starting point is that we had no experience in embedded programming. So we’llspend the first half of the project will be spent acquiring these skills. Fortunately Dickhas lots of robot stuff from his day job and was able to lend us lots of robots. We’vegot to work with two brand new products – Parallax’s Boe-Bot Shield for the Arduinoand ROBOTC programming for Arduino – before they’ve released. And a manufactureris lined up to donate a quadcopter in return for mention in one of our articles.
Pictures, Pictures, Pictures
 
Arduino Embedded Controller
 The Arduino CPU boards have gained immense popularity over the last few yearsbecause of their low cost and ease of use. An Arduino uses an Atmel AVR CPU withon-board I/O support. It's an open hardware design which means the schematics,circuit layout data, and parts list are all freely available for anyone to build their ownboard instead of buying a pre-assembled version. This is the hardware equivalent of open source software.It is based on flexible, easy-to-use hardware and software. Several factors contributeto its popularity:
 The controller comes “ready to run”. Simply connect a battery and yourperipherals – servos, motors, switches, sensors, buzzers, etc – and you’re ready toprogram.
It has a very small learning curve. Starting from scratch you can be up andprogramming with an hour or two.
It’s inexpensive. The Arduino UNO circuit board is around $30. A larger size (70 vs20 I/O version) is available for $65.
 The value of an Arduino is not simply the hardware. It's also the softwareprogramming solution, documentation and tutorials that make it an attractivesolution.
 The Arduino programming environment is easy-to-use for rank beginners, yetflexible enough for advanced users to take advantage of as well.
It’s based on open source software and hardware that can be easily extended.
It’s programmed via a simple USB cable connected to the PC.Hundreds of thousands of Arduinos have been sold over the last few years. It’s not just used for robots. It's intended for artists, designers, hobbyists, and anyoneinterested in creating interactive objects or environments.
 
Arduino Programming Environment
 A key element of the ease of use of Arduino is the intuitive programmingenvironment. It has a single Window and a minimum of menu commands and buttons. The two most important buttons are the “Verify” and “Upload” buttons. “Verify” justruns the compiler and identifies errors and bugs within the sketch. “Upload” runs boththe compiler and uploads the sketch to the Arduino board. Other button that mayhold significance is the “Serial Monitor.” This prompts up another window anddisplays whatever you want printed on a certain baud rate. We have used the serialmonitor to observe the data collected by the infrared sensor and the sonar sensor. The other buttons are merely for the ease of convenience and include “New Sketch,”“Open,” and “Save.” The Arduino solution has a really easy mechanism for transferring programsdeveloped on your PC into the Arduino CPU flash memory. Programs are downloadedfrom the PC over a standard USB cable connection via a single command in the IDE.Most Arduino boards have an integrated USB connection; there's no need foradditional hardware debugging/downloading devices that are typically used withcommercial / professional development systems. The most difficult part of the setup was definitely finding the right drivers and gettingthe Arduino to connect to the IDE.
Blink Example
Programs are called “sketches” in the Arduino programming environment. Allprograms have the same functionality consisting of two functions. A “setup()”function that is run once on startup and a “loop()” function that is called repetitively.One of the provided example sketches is called “Blink” and is a nice short programthat illustrates this.“Blink” is a simple program to blink a LED connected to pin 13 at a two second rate.

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->