Introduction: Setting Up the Circuit

The following information is a single lesson in a larger project. Find more great projects here.

Return to Previous Lesson: Introduction

Lesson Overview:

Now we'll build our simple circuit!

Step 1: Continue to the Next Lesson to Learn How to Set Up the Circuit! Done

Continue to the next lesson to learn how to set up the circuit!

  1. Connect the 5 volt pin on the Arduino to the red voltage rail on the breadboard.
  2. Connect one of the ground (GND) pins on the Arduino to the black ground rail on the breadboard.
  3. Continue to the next step.

Step 2: Add 3 LEDs

Next you will add the output LEDs: two red and one green.

We refer to the two legs of an LED as an anode and cathode. An anode is the terminal of a component that current flows into -- in this circuit the anode connects to the Arduino pin, where it will receive 5 volts when the pin is turned on.

A cathode is the terminal of a component that current flows from. In this case, current flows from the cathode of the LED, through a resistor, to ground.

In the simulator, you can hover your cursor over each leg of the LED to see its name. The long leg is the anode, and the short leg is the cathode.

  1. Place the 3 LEDs on the breadboard in row E, as shown in the picture. There should be two sockets in between each LED.
  2. Use a 220 ohm resistor to connect each LED's cathode (left leg) to the ground rail of the breadboard.
  3. Connect the anode (right leg) of the first LED to pin 5 on the Arduino.
  4. Connect the anode (right leg) of the middle LED to pin 4.
  5. Connect the anode (right leg) of the green LED to pin 3.
  6. Continue to the next step.

Step 3: Add the Pushbutton

Place the button on the breadboard just as you did in the previous project. Attach one side to power, and the other side to digital pin 2 on the Arduino. (Breadboard picture is in Instruction 1.)

You'll also need to add a 10 k-ohm resistor from the ground rail to the button pin that connects to the Arduino. We call this a "pull down" resistor. When the button is not pressed, the resistor pulls pin 2 down to a value of 0 volts. When the button is pressed, the pin voltage is brought up to 5V.

  1. Place the pushbutton component across the middle section of the breadboard, to right of the LEDs, as shown.
  2. Connect the left side of the button to the 5 volt rail (red) of the breadboard.
  3. Connect the left side of the button to digital pin 2 on the Arduino. Pin 2 will interpret whether the button is pressed.
  4. Finally, add a "pull down" resistor between the left side of the button and the ground rail of the breadboard. Change its value to 10 k-ohms using the dropdown menu.
  5. Continue to the next lesson to learn how to write the Arduino code!

Next Lesson:Writing the Code

Comments

About This Instructable

583views

1favorite

License:

More by circuits:Move Circuit AssemblyGlow Circuit AssemblyIntroduction
Add instructable to: