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

Return to Previous Lesson: Supply a Voltage with Batteries

Lesson Overview:

Now we'll learn about using buttons!

## Step 1: Introduction

In this lesson, you will learn about a simple way to control the flow of current in a circuit - the push button.

This component is used to open and close a gap in the circuit to start and stop the flow of current.

The picture shows what a button looks like on a circuit schematic (the map of your circuit!).

The symbol for the button represents what the button does in real life -- an open gap in the circuit becomes closed when you push down on the button.

Can you think of some electronic devices that use buttons? Your computer has plenty of them, including the keys on your keyboard!

1. Continue to the next step.

## Step 2: Mappping a Breadboard Pushbutton

Our button has four terminals. But wait, our circuit schematic only uses two!

In our breadboard button, the two terminals on the left labeled 11 and 12 (one-one and one-two), are always connected to each other. The two terminals on the right labeled 21 and 22 (two-one and two-two), are always connected.

Pushing the button connects the two sides of the button together.

1. Continue to the next step.

## Step 3: Placing a Pushbutton

Let’s try placing a button on the breadboard. You’ll see in a moment that the button fits perfectly across the middle segment that does not have sockets. You will almost always want to place buttons here!

A breadboard with connected voltage rails is already in the Workplane.

1. Open the Components + tab and bring the pushbutton into the Workplane.
2. Place the pushbutton so the bottom two terminals sit in sockets F16 and F18. Notice that the top two terminals of the button snap directly into sockets E16 and E18.
3. Can you identify which columns of sockets are connected now? (see hint)
4. Press the next button below to continue.
5. Stuck? HINT: columns 16 and 18 are connected from top to bottom

## Step 4: Creating a Button Circuit

In this step you will control an LED using a button.

The breadboard, button, and voltage rails are already set up.

1. Return to the Components + menu and add an LED breadboard. We suggest placing it in sockets F22 and F23.
2. The LED needs a resistor to protect it! Open the Components + tab and add a resistor to the Workplane.
3. Rotate the resistor vertically and place it in series with the LED. We suggest placing it on the breadboard so it shares a connection with the right (anode) terminal of the LED.
4. Connect a wire between the red (+) terminal of the battery to the right terminal of the resistor.
5. Next connect a wire between the left terminal of the LED to the right side of the button.
6. Finally, connect the left side of the button to the blue (negative) voltage rail.
7. Press the “next” button below to continue.

## Step 5: Pressing the Button Two Ways

Try simulating the circuit by pressing the “Start Simulation” button. Click the button with your cursor. What happens to the LED? Can you identify what connection is made to complete the loop? See the picture for the answer.

The breadboard button actually functions as two different kinds of buttons.

Momentary button: The button only forms a connection while you are pressing it. Releasing the button breaks the connection. A computer key is a momentary button!

Latch button: The button forms a connection with a single press and locks in place. Pressing the button again releases the connection.

In the simulator, press the SHIFT key while pressing the button to turn it into a latch button.

1. Press the button by clicking with the cursor. The Light comes on.
2. Release the button. Does the light turn off? The button acts like a momentary switch.
3. Now hold down the shift key and press the button again with your cursor.
4. Release the button. Does the light stay on? The button acts like a latch switch.
5. Practice pressing the button with our without the shift key on before moving onto the next step.
6. Press the “next” button below to continue.

## Step 6: Adding Buttons in Series

In this part of the lesson you’ll use buttons in series or in parallel.

First we’re going to add an extra button to the circuit, in SERIES…

Components in series share a connection between just one of their terminals. Wires connecting from the other terminals continue on to link up with the rest of the circuit. The schematic represents two buttons in series.

Both buttons must be pressed to complete the circuit.

1. Make sure the simulation is not running. If it is, press the “Stop Simulation” button.
2. Copy the button that is currently on the breadboard by highlighting it and typing control or command-C on the keyboard.
3. Paste the button in the Workplane by typing control or command-V on the keyboard.
4. With the button highlighted, place it on the breadboard with the bottom terminals on sockets F12 and F14.
5. Name the left button Button 1 and the right button Button 2.
6. You need to delete a wire in order to incorporate the new button into the circuit. Highlight the wire connecting Button 2 to ground and delete it by pressing the garbage can button.
7. Connect a new wire between the right terminal of Button 1 and the left terminal of Button 2.
8. Finally, connect a wire between the left terminal of Button 1 and the blue (ground) rail.
9. Simulate the circuit! Try pressing the buttons while holding down the shift key. What happens when B1 is pressed? B2? What if both buttons are on at the same time?
10. Press the “next” button below to continue.

## Step 7: Connecting Buttons in Parallel

Next we’re going to add an extra button to the circuit, in PARALLEL.

Components in parallel share a connection between two their terminals. The schematic above represents two buttons in parallel. Only one button needs to be pressed at a time in order to operate the LED.

1. Make sure the simulation is not running. If it is, press the “Stop Simulation” button.
2. Move Button 1 from its current position to the sockets directly above Button 2 (D16 and D18).
3. You need to reconnect some of the wires. Start by deleting any dangling wires on the board that don’t connect components together by highlighting them and pressing the delete key.
4. Connect a new wire between the left terminal of B1 and the blue (ground) rail.
5. Simulate the circuit! Try pressing the buttons while holding down the shift key. What happens when B1 is pressed? B2? What if both buttons are on at the same time?
6. Press the "next" button below to continue.

## Step 8: Shorting a Component (part 1)

You have seen two methods for controlling circuits with buttons. Finally we will cover a third method and learn a new circuit term: shorting a circuit.

Remember that you learned in the resistor lesson that current always tries to find the shortest path through a circuit. If you directly connect the terminals of a component with a wire, current will flow through the wire instead of through the component!

This kind of connection is actually called a “short!” The current flow is taking a detour through the wire.

You can demonstrate this concept easily on the breadboard by shorting the terminals of the LED together with a wire.

One button, two buttons… nothing will make the LED come on! Current is flowing through the short wire between LED terminals instead of through the LED.

1. Connect a wire between the left and right terminals of the LED
2. Simulate the circuit
3. Try pressing the buttons one at a time or pressing several at the same time.
4. Press the “next” button below to continue.

## Step 9: Shorting a Component (part 2)

In the final step, you will create a short circuit using a button. This is an interesting way to use a button to turn an LED on and off.

When the button is off, the LED is on. When the button is pressed, the LED is off. Based on the schematic below, are the LED and button in series or in parallel? (see hint)

1. If the simulation is still running, turn it off by pressing the Stop Simulation button
2. Next, you will re-create a simple LED and resistor circuit. Start by deleting the wires connecting the buttons to the rest of the circuit. Delete Button 1 as well.
3. Delete the wire that is shorting the two terminals of the LED together.
4. Connect a wire between the left (cathode) terminal of the LED and the blue (ground) rail.
5. Stop adjusting the circuit for a moment and try simulating the circuit by pressing the Start Simulation button. Does the LED turn on and stay on?
6. Stop the simulation and continue onto the next instruction.
7. Finally, you will connect Button 2 in parallel with the LED. Connect a wire from the right terminal of the button to the right terminal of the LED.
8. Connect a wire from the left terminal of the button to the left terminal of the LED.
9. Simulate the circuit. What happens when you turn the button on and off?
10. Stuck? HINT: Button and LED are in parallel, they share two connections.

## Step 10: How Will You Use a Button?

In the time that you have remaining, try creating circuits with three buttons in parallel or three buttons in series. Or try a combination of series and parallel buttons.

Congratulations, you have simulated at least three ways to use buttons in a circuit! All of these concepts will be useful for the final project: The Secret Code Keypad.

In the next lesson you will learn to create custom colors with an RGB LED!

Next Lesson:Circuits in Practice: RGB Color Mixer

### About This Instructable

159views

2favorites

License:

More by circuits:
Add instructable to: