Hi there!

If you're here, it's because you want to learn how to build and make stuff with electronics! (If, rather than learn electronics, you'd like to look at pictures of cats instead, please check https://www.adafruit.com/galleries/cats-of-engineering)

And, you're in luck: there's never been a better time.

Gone are the days where you need thousands of dollars of equipment and lots physics/math background. Nowadays, if you want to learn to work with electronics, you can jump right in for $100 or less, and any sort of computer. And we're talking about learning a lot of electronics - from the basics of analog to the complexities of firmware. With a good pack of parts, you can build a base of knowledge that will take you from your first blinking LED to someone who can start prototyping and inventing custom products.

Who is this for?

Anyone with a computer they can install software on, an Arduino or compatible and the ability to type and click a mouse. That's pretty much the minimum.

You don't need to know a lot of physics or math, and just like an Art Degree isn't required for making art and being creative, you don't need to have a computer science degree. It helps if you're comfortable using computers but that's a skill most people pick up through life.

If you know how to program already - great! If not, don't worry, we'll teach you enough to be dangerous.

Who are you?

Great question. This is me:

Temporarily unable to load embedded content:
https://www.youtube.com/watch?v=lHC10q_a7Nc

I'm Ladyada, and I love to teach people how to build stuff and how they can be creative with technology.

So, are you ready?

Let's do this thing!

What is an Arduino?

Arduino is the name of the little electronic circuit board that you are going to use as a tool to investigate and explore programming & electronics.

It is manufactured by arduino.cc a company led by Massimo Banzi, CEO of Arduino. Here is how they describe themselves:

Arduino is an open-source prototyping platform based on easy-to-use hardware and software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing something online. You can tell your board what to do by sending a set of instructions to the microcontroller on the board. To do so you use the Arduino programming language (based on Wiring), and the Arduino Software (IDE), based on Processing.

Over the years Arduino has been the brain of thousands of projects, from everyday objects to complex scientific instruments. A worldwide community of makers - students, hobbyists, artists, programmers, and professionals - has gathered around this open-source platform, their contributions have added up to an incredible amount of accessible knowledge that can be of great help to novices and experts alike.

Here's a photo of Massimo and I at the Adafruit factory, showing off the first Arduino UNO made in the USA!

About This Lesson

This lesson won't teach any electronics, really. Its more for making sure that everything is setup and ready for the future lessons. It will verify the board is working as intended and that the computer you are using is compatible.

Think of this tutorial as the 'home base' of your journey. If things ever get into a weird spot come back here and re-verify this lesson!

One of the most important skills you'll have to learn is that when things go wrong (and they will, tons) come back to the most basic assumptions. This is a little bit of the "are you sure its on" of electronics. It's surprising how many skilled engineers will spend hours debugging a circuit to realize that...it wasn't plugged in!

Which Arduino?

In the ten years since Arduino was first released, there's been a huge proliferation of hundreds of different "Arduino boards" available. On one hand, there's an Arduino for just about every kind of specialized purpose, but on the other hand - it can get quite confusing!

In this tutorial we'll be focusing on the Arduino UNO which is the classic Arduino, by far the most popular and is what 99% of projects use. It's basic, well supported, and is a great starter-duino.

As you do more you will find that there may be other Arduino compatibles you could want!

For example the Arduino Mega is...well, Mega! Its a big sister to the UNO with a ton more memory and pins, and a different chip, the ATmega2560. It's a good upgrade when your project no longer fits in an UNO

The Arduino Micro, on the other hand...is a bit smaller! It has a different Atmega32u4 chip that can do native USB so it can act like a keyboard or mouse. Its slim and has downward-pin headers so you can plug it into a breadboard.

The Arduino MKR1000 is a little like an Arduino Micro but has a more powerful 32-bit ATSAM ARM chip and built-in WiFi! A great upgrade for when you want to do Internet of Things projects

There's also Arduino-compatibles like the Flora we make here at Adafruit. It's a round wearable Arduino and rather than use wires you can sew it into clothing for portable soft-electronic projects

And really, there are hundreds of others... once you start with the Arduino you can take it anywhere!

Lesson Parts

Required:

Assembled Arduino board, preferrably an Uno or Duemilanove (or whatever the latest version is)

Arduino compatibles will work but there's a lot of issues with ultra low cost 'Arduino compatibles' (e.g. eBay, Amazon, etc) where they have shoddy substitutions that can bite you later. It's good to have at least one known-genuine Arduino UNO!

Available at Adafruit

You can also use an Adafruit Metro which is a drop-in replacement for the UNO, some components like the LEDs are in different locations.

Available at Adafruit

USB Cable, any length. The cable should match your Arduino's USB connector. Official Arduino UNOs use USB "Printer Cable", a blocky cable. Some compatibles use USB Mini-B or Micro-B.

USB Cables available at Adafruit

A HUUUUUUGE number of people have problems because they pick a 'charge only' USB cable rather than a "Data/Sync" cable. Make 100% sure you have a good quality syncing cable. Srsly, I can't even express how many times students have nearly given up due to a flakey USB cable!

Not Required but... Recommended!

A plug in wall adapter is handy if you want to run your Arduino project 'standalone'

You can use any adapter that is Center Positive and 7 to 12VDC output - we recommend 9V DC if possible Check the second photo for the symbol that indicates Center Positive and for the 9V output text. The Arduino is fairly rugged and can survive plugging in the wrong adapter as long as the voltage isn't higher than 20V but it's 'stressful' to the 'duino and you should aim for 9V!

Available at Adafruit

4 rubber bumpers

OK these are really optional but we include them because they're so nice to have on an Arduino and they help keep your table from getting scratched up. You can pick these up from a hardware store

Available from Adafruit

Prepare the Arduino

Ah time to get your little hands on the hardware.

Take your Arduino out of its protective bag or box. Look at it and make sure it looks kinda like this:

Check It Out

If there's anything missing or really wrong, make sure to contact the store you bought it from. For example, here is an Arduino that is missing the two round silver capacitors! (This is extremely rare but it has happened)

If you have an Arduino compatible, it might look a little different. For example, here's an Adafruit Metro.

If you're using a compatible, make sure that for sure:

  • It is an Atmel ATmega328 or Atmega328P
  • There are headers for plugging wires into
  • It runs at 5V (check the product documentation)
  • It has a USB-serial chip on board, such as FT232, FT231x, PL2303 or CP2102/CP2103/CP2104 which are the most popular and a USB plug

We'll discuss these parts in more detail later but, sometimes 'Arduino compatibles' use completely different chips, so the most important thing is that is an ATmega328 at the core.

Bump it!

OK, now that you are satisfied that your Arduino looks good, put the rubber bumpers on the bottom of the board. This will protect your Arduino from spills and dirty tables. If your table is made out of metal, this is essential!

Keep your desk clean and keep the 'duino away from paperclips or other metallic items

If your Arduino came with a silver antistatic bag, don't place the Arduino on top of it while in use! The bag is conductive and can cause all sorts of problems. (You can store it in the bag when not in use, though)

Take a Tour!

It's handy to know the names for parts of a cow when talking about cuts of meat!

Here we'll take a tour and point out the names of the Arduino. You'll want to refer back to this page a ton, so keep it handy when we say something like "DC Jack" or "RX and TX LEDs"

The Parts of an Arduino

Here's a rough version of the parts of an Arduino we'll refer to. First up is the Arduino UNO R3, at the time of writing it's the most popular Arduino. Each part is covered in more detail in the next sections

Here is an Arduino compatible, Adafruit Metro.

You'll notice that some things are the same

  • Same overall board size and shape
  • Same location of holes (used for attaching the board to something)
  • Reset button in the same location
  • High and Low Digital Header in the same location
  • Power and Analog Header in the same location
  • DC Power Jack in the same location

Some things are similar

  • Both have a USB Jack, but the UNO has a large style USB jack, the Metro has a USB Micro jack
  • Both have a Fuse but in different locations and different look
  • Both have a 5V power supply, but in different locations and organized a little differently
  • Both have four LEDs: Pin 13 LED, RX and TX LED, and ON LED. But they are in different locations. The UNO has them in the middle of the board, the Metro they are all on the left.
  • Both have the same Headers but Metro may have the headers soldered on the top whereas the UNO has the pins go through the board and soldered to the bottom.

Some things are different!

  • Both have a USB Interface chip, but they are different parts. They act almost the same but the driver is different. This only matters the first time you install the software
  • UNO has a large silver Crystal, but the Metro does not (the USB interface chip on the Metro doesn't use a crystal)
  • UNO has a large socketted ATmega328 chip. Metro has a slimmer square version that is not in a socket.
  • Metro has an On/Off switch, this lets you turn off the power when plugged into DC power. UNO does not have one, its not required just a nicety

Power Up Test

Now we are ready for the moment of truth, it's time to plug your Arduino in and power it up. The easiest way to do this is to plug one end of the USB cable into the Arduino and the other end into a computer. The computer will then power the Arduino.

For an Arduino UNO, you'll need a USB cable with a square B-type end:

Make sure that the USB cable is plugged in directly to a computer port. Sometimes monitors or keyboards have a USB port you can plug into. Most of the time this is fine, but I strongly suggest you plug it directly into the computer as that will eliminate any possible problems. Same goes for USB hubs - skip those for now and go direct

Later on, once you've verified you can power the Arduino and upload sketches no problem, then you can try plugging it into other ports.

OK anyways, so plug int he USB cable and check that your Arduino looks like this:

In particular, make sure the green ON LED is lit! The yellow or red L LED might also be lit or blinking, and the RX and TX LEDs might be blinking or lit right after plugging in - this is normal.

If no lights or blinking occurs, double check:

  • Is the USB cable plugged into the computer and into the Arduino?
  • Try another USB cable
  • Check there's nothing metallic touching the Arduino that could be shorting out the device
  • Is the computer on?
  • Try another USB port, USB cable, and computer?

If you still can't get it working, your Arduino may be faulty.

Bootloader Reset Test

Next up, you can do a quick bootloader test - this will let you know that the Arduino chip has been programmed with a bootloader which is required!

While powered, click the Reset button - you will see the L LED blink 3 times very rapidly. Don't worry about counting the blinks, just make sure it flashes quickly when reset.

DC Power Test (Optional)

Another way to power up the Arduino is to plug in a battery or wall adapter into the DC jack.

Verify that you have a 9V DC 100mA or greater power adapter, with a 2.1mm barrel plug and positive tip.

If the box doesn't have any information about the adapter, you can look for these clues.

Make sure the symbol near the bottom of the label is present. It means that the outside of the plug is negative and the inside is positive. A center-negative plug will not work with the Arduino.

To verify the DC plug is the right shape, just try plugging it in. If it doesn't fit or is wobbly, it's the wrong kind. You can learn how to test wall adapters using a multimeter here.

Plug in the adapter and verify you get the green ON light!

If not, double check:

  • Is the DC adapter plugged in?
  • Is the DC adapter the right kind? Check voltage, polarity, plug size, etc.
  • Try another adapter.

If you still can't get it working, your Arduino or wall adapter may be faulty.

Download Software

To get you all set up, start by installing the Arduino IDE Software

This is the free application you'll use to write programs and talk to your Arduino or compatible. Did we mention it is free? How awesome is that?

You can download Arduino from

https://www.arduino.cc/en/Main/Software

There's a lot of other companies and groups that may try to get you to download the Arduino software but it could have viruses or malware. Only download from arduino.cc !

When you visit the Arduino site you'll see a section like this:

The Arduino software is under constant revision. As of this writing, the version available is 1.6.9 but you may have a more recent version. Just grab whatever is the most recent

Windows

Download and install with the Installer. The Zip file (non-admin install) is not recommended unless you cannot run the installer

Mac

Download and drag the Application out of the compressed folder.

Linux

Available for 32-bit or 64-bit Linux, once you download you will need to manually decompress and install

Raspberry Pi and other ARM-based Linux

There's a new version you can use that is compiled for ARM processors! It works on the Raspberry Pi and will likely work on any other ARM core Linux

This guide was first published on Jul 14, 2016. It was last updated on Jul 14, 2016.