Lights, Jumpers & the Resistance –
Jumper wires are typically 22 gauge solid-core wires with insulation pre-stripped and readied for insertion in or out.
Resistors resist the flow of electrical current, thereby controlling WHERE and HOW FAST it flows. [Thought experiment: If controlling water, using thin pipes would let less water through but would flow through faster than a similar amount of water in a thicker pipe, albeit the latter would let a larger quantity of water through. If you had a fire hydrant, you want high resistance, i.e. highly pressurized water: if you have a water fountain, you might prefer less resistance, and less pressure. If you had the pressure from a fire hydrant in a water fountain, this would lead to a very unpleasant drinking experience, and water fountain-level pressure in a fire hydrant would lead to happier arsonists.]
An LED is a light emitting diode. A diode lets current flow only one way, from positive to negative. An LED has a quick distinguishing feature: the positive leg/ lead is visibly longer than the negative lead. If the leads are clipped, there are 2 other ways to tell: (1) the anode (in a device that consumes power, the anode is positive, but in a device that produces power, the anode is negative) or positive is going to be the bigger metal piece inside a transparent LED, or (2) test using a power source.
Resistance is measured in ohms, written Ω. The bigger the Ω, the greater the resistance. Measuring resistance can be done either by color-coordinated stripes on the resistor’s body (resistor color code), or more accurately using a multimeter. A resistor is the same from either pin/ end; there is no forward or backward direction.
Breaking out my breakout board –
The breakout board is an extended pin-out from the Pi, to the breadboard ( or any other device for that matter). It replicates the existing pin-out on the Pi, communicating through the ribbon cable.
A breadboard (pictured below) is a device used for prototyping circuits. It allows easy and fast access of components: as fast as you can pull out a thin wire from a slot. One of its advantages is that it does not need soldering, which makes most n00b errors, mulligans. A breadboard is basically a plastic brick/ block that has a lot of holes, typically spaced 0.1″ apart. Into these holes doth one plug in leads/ wires, that are then held in place by metal contacts. There are many columns, in my case, numbered long-side from 1 – 30, and short side from a – j: 30 holes by 10, for a total of 300. In addition, there are +ve and -ve holes on either side of these 300, each 2 holes by 5 per chunk, by 5 chunks per side, i.e. 50 per side and 100 total +/- holes. The +/- is the power and ground rail respectively.
It is important to understand how these rows and columns work. If you put power into, say, the right side the whole row, i.e. from the red + straight down to the other red + only on that side. The same applies for the negative (ground), and the same applies for the other side. Within the body, the lettered/ numbered holes (not in the power rails), work the opposite way, i.e. in columns, and only on its side of the center ridge. Plugging a jumper wire into c-28 would communicate with a-28, b-28, d-28, and e-28. It wouldn’t communicate with f-28, because of the ridge’s separation. You don’t have to match power/ground, simply powering/ grounding one side effectively performs that action to all the holes on that side of the power rail. To reiterate, from a to a or – to – is a row, and from 25 to 25 is a column.
Notice the bridge in the center: this literally and electrically separates either side of a breadboard. When a side is live, i.e. there is current flowing through it, the live “holes” will light up, but that’s another story we haven’t gotten to yet. Breakout boards attached should be attached on opposite sides of this bridge: if not on opposite sides, will lead to a over-baked Pi.
Armed to the gills, I set out to complete several of the online tutorials from Adafruit/ LadyAda.net & Cambridge.
Step 1: Plug in the breakout board.
The two rows of pins MUST be on opposite sides of the center ridge, and firmly seated after aligning the pins with matching holes. The Pi should not be plugged in at this point.
Step 2: Juice!
For power, we shall connect the ‘3V3’ pin, that has, shockingly, 3.3V. The 3V3 pin is connected to the power rail, and to the corresponding hole in the board that the 3V3 is in. The same is done for the GND, the ground pins. When we connect the Pi in upcoming steps, the current shall flow through these connections, completing the circuit and powering the breadboard.
Step 3: L-E-D to G-P-I-O
Pin Out Diagram:
The next step is wiring the LED into the board. There are 2 considerations: connecting the positive lead (longer) to a GPIO pin ( I used GPIO pin 0 – SDA) and connecting the negative lead of the LED to the ground using a resistor. This is easier than it sounds: we use a jumper wire from the column the GPIO pin is in, and connect it to a free column anywhere. We then connect the positive lead of the LED to the same free column we have chosen. For the negative lead of the LED, one connects it to any different free column, and subsequently connects any end of a transistor to that same column. This is then connected to the ground, leading to the circuit being completed, via the resistor.
Once you connect the Pi to a power source, the Pi’s red PWR LED should turn on as well as the LED on your breadboard.