top of page

Lab 2: Digital I/O Breakout Boards

In this lab you will get set up with the Arduino prototyping environment and explore digital inputs and outputs using a microcontroller. You will also learn to solder and create two custom breakout boards, one input and one output. 

Digital I/O Circuit

For this part of the lab, the idea was to use two buttons or switches in order to control a strip of NeoPixels through the use of an Arduino program. First, I soldered three wires to the end of the NeoPixel strip, one for power, one for ground, and a signal wire to connect directly to the Arduino. Then I connected my Arduino to the computer and ran a preset sketch just to test and see if my NeoPixels were working. 

Quick schematic drawing of the circuit

IMG_1976.HEIC
IMG_1947.HEIC

Testing the NeoPixels first

After I got my NeoPixels to light up, I added another button and slightly changed the configuration. I had some trouble with my buttons at first, but I realized that I just had them turned sideways. Once I got my buttons in the right configuration, the code that I had written started to work. The red button turns the strips from the bottom to the top to one color, the black button turns the button to another color, and I tried to write code for when both buttons are pushed, and it worked! When neither of the buttons are pushed, the NeoPixels are off. 

IMG_1960.HEIC

Final Code for the NeoPixels (scroll)

Soldered Breakout Boards

Digital Input Breakout Board

For the input breakout board, I soldered a wire to the two the outside pegs on a switch, and soldered a resistor (a standard 10K for the Arduino) to the middle peg. So there were three wires coming from this breakout board; power, ground and signal (which goes to a pin on the Arduino)

IMG_1974.HEIC

Schematic drawing of the digital input circuit

Back of the input board

IMG_1967.HEIC

Front of the input board

IMG_1968.HEIC

Digital Output Breakout Board

For the output breakout board, I soldered a wire to a resistor, and then soldered that to 2 LEDs that were in a series. Using Ohms law, I found out that I would need a resistor of about 50K, but I went up and used a 100 Ohm one. This breakout board was much more confusing together, so I made sure to keep all of the wires organized so I would mix anything up. 

IMG_1975.HEIC

Schematic drawing of the digital output circuit

IMG_1973.HEIC

Back of the output board

IMG_1972.HEIC

Front of the output board

Then I connect one of the outside wires from the input board to the power pin on the Arduino, and I put the other one in a ground pin, then I stuck the signal wire into a pin. Then I took the side of the output board that would take in the power and lead to the resistors/LEDs and chose another pin. Lastly I put the second wire on another grounding pin. Then I wrote some simple code to turn the LED's on digitally from the switch. Since I had done the NeoPixels first, this part of the lab made so much more sense, and the code was decently easy to figure out.

IMG_1969.HEIC
IMG_1970.HEIC

© 2023 by Meganne Jimenez. Proudly created with Wix.com

bottom of page