arduino programming 101 - wordpress.com · an arduino board (arduino uno) solid copper wires (for...

9
http://robotsclub.wordpress.com Arduino Programming 101 Lesson 1: An Introduction to Programming

Upload: others

Post on 15-Nov-2019

43 views

Category:

Documents


2 download

TRANSCRIPT

http://robotsclub.wordpress.com

Arduino Programming 101Lesson 1: An Introduction to Programming

http://robotsclub.wordpress.com

Topics to be Covered

What is “Arduino”?

Set Up a Development Environment

Helpful Resources

Image Courtesy of openclipart.org

http://robotsclub.wordpress.com

What is Arduino?The Arduino is a small circuit board with an on-board processor chip and storage to hold and run programs

There are a number of inputs and outputs that allow the Arduino to be programmed to send and receive electrical signals

The programs are written in the Arduino Programming Language, which is very similar to C/C++

We will be using the Arduino much like the Mindstorms NXT to read input from ultrasonic and light sensors and send commands to motors on the robot

Arduino Open-Source Community Logo from arduino.cc

http://robotsclub.wordpress.com

Required MaterialsAn Arduino Board (Arduino UNO)

Solid Copper Wires (for connecting sensors to Arduino)

A USB connector to upload program to Arduino

**The Mindstorms NXT cables work for Arduino**

Various Sensors (Ultrasonic, Photoresistor, Motor Controller, etc)

Battery Power Source (Will be custom-made in a later lesson)

A computer for programming

http://robotsclub.wordpress.com

First StepsBefore we begin working with the Arduino boards, we need to set up a development environment

Navigate to http://arduino.cc/en/Main/Software and under the Arduino IDE heading, find the latest version (1.0.5 at time of writing) and download the version for your operating system

Open the downloaded file and follow any on-screen instructions to install the software

http://robotsclub.wordpress.com

Basics of Arduino SoftwareAn Arduino program is referred to as a Sketch

The program has a built-in compiler that will verify your code before you can upload it to the Arduino

Under the File menu, there’s an Examples list with tons of pre-written programs for the Arduino to use as starting points

In our next lesson, we will be using these examples to write some basic Arduino code

http://robotsclub.wordpress.com

Helpful ResourcesArduino Examples: http://arduino.cc/en/Tutorial/HomePage(Each Example from the menu explained online)

Arduino Reference: http://arduino.cc/en/Reference/HomePage

Arduino Forums: http://forum.arduino.cc (Huge group of people with tons of experience and knowledge - search for questions - odds are someone else had the same problem and already found a solution)

http://robotsclub.wordpress.com

My Webpage

http://robotsclub.wordpress.com

I will post these presentations, tons of helpful websites, images of wiring diagrams, quick tips for programming, and anything else I think you might find useful when creating your Mini-SUMO bot

Check the site regularly for new material!

http://robotsclub.wordpress.com

The EndQuestions? Comments? Concerns? Suggestions? Please let me know!