All of these pins are connected to a microcontroller, which combines a CPU
with some peripheral functions, such as IO channels. Many different types
of microcontrollers are available, but the majority of Arduinos usually come
with an ATmega328, an 8-bit microcontroller produced by a company named
Atmel. Still there are Arduino models—for example, the Arduino Mega or the
Arduino Due—that use more powerful microcontrollers.
Although modern computers load programs from a hard drive, microcontrollers
usually have to be programmed. That means you have to load your software
into the microcontroller via a cable, and once the program has been uploaded,
it stays in the microcontroller until it gets overwritten with a new program.
Whenever you supply power to the Arduino, the program currently stored in
its microcontroller gets executed automatically. Sometimes you want the
Arduino to start right from the beginning. With the reset button on the right
side of the board, you can do that. If you press it, everything gets reinitialized,
and the program stored in the microcontroller starts again. (We’ll use it in
First Version of a Binary Die, on page 45.)
On most Arduino boards you’ll also find a couple of LEDs. You’ll learn more
about them in Hello, World!, on page 16.
Installing the Arduino IDE
To make it as easy as possible to get started with the Arduino, the developers
have created a simple but useful integrated development environment (IDE).
It runs on many different operating systems. Before you can create your first
projects, you have to install it.
Important note: at the time of this writing, two different versions of the IDE
are available (1.0.6 and 1.6.0).
8
Chances are good that the 1.0.x branch of
the Arduino IDE will no longer be maintained in the future. So, you should
use 1.6.x where possible and use 1.0.x only if you need to use libraries that
don’t work on 1.6.x yet. The following instructions refer to the 1.6.0 version.
Installing the Arduino IDE on Windows
The Arduino IDE runs on all the latest versions of Microsoft Windows, such
as Windows 8.1 and Windows 7. The software comes in two flavors: as a
Windows installer or as a self-contained zip archive. Check the Arduino’s
download page
9
for the latest version of either one.
8. There’s even one more for the Arduino Galileo at
https://communities.intel.com/docs/DOC-22226
.
9.
http://arduino.cc/en/Main/Software
Chapter 1. Welcome to the Arduino • 10
report erratum • discuss
www.it-ebooks.info