COMPUTER SCIENCE CAFÉ
  • WORKBOOKS
  • GCSE
    • CAMBRIDGE GCSE
  • IB
  • A LEVEL
  • LEARN TO CODE
  • ROBOTICS ENGINEERING
  • MORE
    • CLASS PROJECTS
    • BLOCKY GAMES
    • Classroom Discussions
    • Useful Links
    • SUBSCRIBE
    • ABOUT US
    • CONTACT US
    • PRIVACY POLICY
  • WORKBOOKS
  • GCSE
    • CAMBRIDGE GCSE
  • IB
  • A LEVEL
  • LEARN TO CODE
  • ROBOTICS ENGINEERING
  • MORE
    • CLASS PROJECTS
    • BLOCKY GAMES
    • Classroom Discussions
    • Useful Links
    • SUBSCRIBE
    • ABOUT US
    • CONTACT US
    • PRIVACY POLICY
Picture
ROBOTICS ENGINEERING | BASIC ELECTONICS
Please note that many aspects of working with electronic components and workshop equipment can be dangerous. This section is designed to provide a platform to help your teacher or supervisor guide you in learning. Incorrect use of equipment or mistakes made with live circuits can cause heat, fire, explosions and serious injuries. Always take care when doing projects and ensure adequate supervision by a qualified person and if needed and wear protective equipment.
SECTION 1 | WHAT IS PROTOTYPING
Prototyping is making a sample to test your ideas prior to making the real thing. It is quicker, cheaper and easier to make a prototype and a great way to test for any potential problems. For small electronic circuits we can use a product called breadboard(as seen below). Breadboard is a quick and cheap way to test and change circuit designs and learn about electronics.
SECTION 2 | BREADBOARD
Breadboard is great for prototyping electronics projects. It is important to understand how electricity will flow through the breadboard and care is needed when connecting your components.
Picture
On the outer rails in each row all of the pins running the length of the board are connected together – the two outer rows themselves are not connected, the two outer rows on the board are often used to supply or distribute the positive and negative inputs or outputs.

The pins in the center are connected in shorter rows of 5 running the width of the board.
​
There is a break in the center of the board where no electricity will flow. This break in the center is designed to be able to mount surface mount chips such as the 555 timer chip, by placing the chip here it ensures that none of the pins on the chip are connected to each other.
SECTION 3 | JUMPER WIRES
Jumper wires are used to make connections on prototype circuits. They normally come pre-cut in different lengths and some may have terminals on the end to make connections easy, the three main types are:
​Female to Female
Male to Male
Female to Male
Picture
​If you get use to calling each type of jumper wire by the correct name it makes it easy when chatting to others in your project team.
SECTION 4 | USING A MULTIMETER
For the basic projects in this section we will only need to use two functions on the multimeter:
  • Testing Voltage
  • Testing continuity
Testing voltage                                     
Circuits in this guide will use a voltage varying from 3v to 9v and to measure this we only need to remember one setting on the multi meter.
Picture
Once you have the Multimeter on the correct setting you simply need to connect the black lead to the negative side of the circuit you are testing and the red lead to the positive side of the circuit you are testing: Note it does not matter if you get this the wrong way around, all that will happen is the meter will show the result as a negative value.

BE CAREFUL – When probing wires and connections be careful that the tips of your Multimeter leads do not join any circuits, hold the leads careful, rest your arms on the desk and carefully touch the leads on the position you want to measure without touching or creating a short on any other part of the circuit.

Testing Continuity
Testing continuity is testing for the ability for a electrical current to flow. It does not mean a electric correct is flowing, just that it is possible for a current to flow through the material or circuit you are checking. You will use this setting a lot when you are problem shooting.
​
First put your multi meter on to the correct setting as highlighted below:
Picture
Now your meter is set up correctly try testing the continuity of different materials by placing each lead on the material. If the meter beeps or the display changes then an electric current can flow through the material.

Try some other objects like the ones listed below to see if electricity can flow through:
  • A cup of water
  • Your finger
  • The connections on a breadboard
  • A resistor
  • A fuse
SECTION 5 | CALCULATING RESISTANCE AND USING RESISTORS
To understand how to calculate the resistor needed for a circuit, here we go through a practical example using a standard LED and a power supply consisting of 4 AA batteries.

Components in Our Example
1. LED (Light Emitting Diode): LEDs are semiconductor devices that emit light when an electric current passes through them. They require a certain forward voltage (Vf) to light up properly, and they only allow current to pass through in one direction.

2. AA Batteries: Each AA battery typically has a voltage of 1.5V. When batteries are placed in series (end-to-end), their voltages add up. So, 4 AA batteries will give us 4 x 1.5V = 6V.

Understanding the LED Specifications
To select the right resistor, you need to know two key specifications of your LED:
  • Forward Voltage (Vf) | This is the voltage required to get the LED to conduct and light up. Common values are around 2V for red LEDs, 3.2V for blue and white LEDs, etc.
  • Forward Current (If) | This is the current at which the LED should operate to be bright without getting damaged. Typically, this is around 20mA for many standard LEDs.

The Goal
The purpose of the resistor in an LED circuit is to limit the current so that the LED receives its rated forward current and no more. Too much current and the LED will burn out, too little and it won't light up.

Calculating the Resistor Value
To calculate the resistor value, you use Ohm’s Law, which states that V = IR, where V is voltage, I is current, and R is resistance. Rearranged to solve for resistance, the formula is R = V / I.

Here are the steps to calculate the resistor value
1. Total Supply Voltage (Vs) | The sum of the voltages of the batteries in series.
   - Vs = 4 x 1.5V = 6V

2. LED Forward Voltage (Vf) | Let's assume we're using a red LED with a forward voltage of 2V.

3. LED Forward Current (If) | We'll use the typical 20mA, which is 0.02A.

4. Calculate Voltage Across the Resistor (Vr) | This is the voltage you need to drop across the resistor.
   - Vr = Vs - Vf
   - Vr = 6V - 2V = 4V

5. Use Ohm’s Law to Find the Resistor Value (R) |
   - R = Vr / If
   - R = 4V / 0.02A
   - R = 200Ω

Choosing a Resistor
You would select a resistor with at least the calculated value or the next highest standard value if the exact value isn’t available. Resistors also have a power rating which is important to consider. The power (P) dissipated by the resistor can be calculated using P = Vr * If. In our case, P = 4V * 0.02A = 0.08W. You would select a resistor with a power rating greater than this value, commonly a 1/4W (0.25W) resistor is used for small LEDs.

So, you would use a 200Ω resistor with a power rating of at least 1/4W for your circuit. If a 200Ω resistor isn't available, you might use a 220Ω resistor, which is a standard value, and the LED will still operate safely, albeit with slightly less current which is generally acceptable.

Putting It All Together
1. Connect the positive end of the battery pack to one end of the resistor.
2. Connect the other end of the resistor to the anode (longer lead) of the LED.
3. Connect the cathode (shorter lead) of the LED to the negative end of the battery pack.

This completes the circuit, and your LED should light up, given that all connections are made correctly and the LED is functional. Always remember to double-check the polarity of the LED and ensure the batteries are fresh for optimal performance.
SECTION 7 | CREATING CIRCUITS
Building circuits is an essential skill in electronics, where individual components are linked to create a path for electrical current. In this section, we’ll cover the basics of what makes a complete circuit, common mistakes to avoid, troubleshooting tips, and an introduction to testing circuits for voltage and continuity.

What is a Circuit?
​
A circuit is a closed loop that allows current to flow from a power source, through various components, and back to the source. The most basic circuit involves a power source, like a battery, connected to a load (such as a resistor or LED) by conductors (usually wires), completing the loop back to the negative terminal of the power source. For current to flow, the circuit must be complete—meaning there are no breaks or open connections.
  • Positive to Negative Flow: In a simple circuit, current flows from the positive terminal of the power source, through the components, and back to the negative terminal.
  • Direct Current (DC): In most beginner circuits, direct current (DC) from a battery is used. DC flows in one direction, from the positive side to the negative side.

Things to Avoid When Building Circuits
  • Short Circuits: A short circuit occurs when the positive and negative terminals are connected directly, without any load (such as a resistor) in between. This causes a large amount of current to flow, which can damage components or even cause the battery to overheat.
  • Overloading Components: Using components like LEDs or resistors that are not rated for the voltage or current in your circuit can cause them to burn out or fail. Always check the ratings of each component to ensure compatibility.
  • Reversed Polarity: Many components, such as LEDs and capacitors, are polarized, meaning they only work if connected in the right direction. Reversing the polarity can damage these components or prevent the circuit from working.

Troubleshooting Your Circuit
When your circuit doesn’t work, troubleshooting is a critical skill. Here are some common steps to diagnose and fix issues:
  • Check Connections: Ensure all connections are secure, and there are no loose wires or improperly inserted components. Double-check the orientation of polarized components like LEDs and capacitors.
  • Verify the Circuit Design: Review your circuit diagram or design to ensure that every connection is correct. Misplacing even a single wire can prevent the circuit from functioning.
  • Test Individual Components: If a component is suspected to be faulty, remove and test it with a multimeter to confirm that it’s working. For example, check the resistance of resistors or the voltage drop across an LED.

Testing Voltage and Continuity
One of the most useful tools for testing circuits is the multimeter, which can measure voltage, current, and continuity.
  • Voltage Testing: Set your multimeter to the appropriate voltage range and measure across components to ensure they are receiving the correct voltage. For example, when checking a battery, place the probes on the positive and negative terminals to confirm it’s delivering power.
  • Continuity Testing: Use the multimeter’s continuity mode to check for open circuits. If there’s a break in the path of your circuit, the multimeter will not beep, indicating the circuit is incomplete.

Polarity and Its Importance
Many components in a circuit are polarity-sensitive, meaning they must be connected in a specific direction to function correctly:
  • LEDs: The longer leg (anode) must connect to the positive terminal, and the shorter leg (cathode) to the negative.
  • Capacitors (Electrolytic): These also have a positive and negative side, and reversing their polarity can cause them to fail, sometimes explosively.
Always check the datasheets or markings on the components to ensure proper orientation.

Series vs. Parallel Circuits
There are two primary ways to arrange components in a circuit: series and parallel. Understanding these configurations will help you design more complex circuits.
  • Series Circuits: In a series circuit, components are arranged in a single path. Current flows through each component one after another. The total resistance is the sum of the individual resistances, and the same current flows through each component. If one component fails, the entire circuit stops working.
  • Parallel Circuits: In a parallel circuit, components are arranged in multiple paths. Each component has its own path to the power source, so if one component fails, the others continue to function. The voltage across each component in parallel is the same, but the current divides among the different branches.
Experimenting with both types of circuits will help you understand how to control current and voltage in different parts of a system.
SECTION 8 | JOINTS, WIRES AND HARNESSES
When building more complex circuits, especially for Arduino or Raspberry Pi-based projects, managing your wiring is crucial for both functionality and aesthetics. In this section, we'll cover best practices for choosing wire colours, making solid connections, and organizing your wiring to ensure your circuits are neat, easy to troubleshoot, and reliable.
Choosing the Right Wire Colours
Using a consistent colour scheme for your wires is essential in making your circuits easier to understand, debug, and maintain. When every wire has a specific purpose based on its colour, you can quickly identify power, ground, and control lines. This practice is particularly important in projects involving microcontrollers like Arduino or Raspberry Pi, where you often have multiple connections to manage.
Here’s a standard colour coding scheme you can adopt:
  • Red: Power (positive voltage). Use red wires for permanent power lines that provide voltage to your components.
  • Black or Brown: Ground (negative voltage). Black is traditionally used to represent ground, or the negative side of your circuit. For consistency, always use black or brown for ground connections.
  • Yellow or White: Control signals. These wires carry data or control signals between components. For example, if you're controlling a motor or an LED through a GPIO pin, the wire should be a different colour to signify it's not power or ground.
  • Green or Blue: Communication lines. If your project involves communication protocols like I2C, SPI, or serial, green and blue are often used for the data and clock lines.
While the specific colours are up to you, sticking to a consistent scheme will make your projects much more manageable, especially when troubleshooting or expanding a circuit later.
Making Strong Connections
Good electrical connections are vital for reliable circuits. Here are a few tips to ensure your connections are solid:
  • Solder Joints: When working with more permanent connections, such as between components on a PCB or attaching wires to a motor, soldering is the best option. A good solder joint should be shiny and form a smooth connection between the wire and component. Avoid cold or brittle joints, which can lead to intermittent connections.
  • Twist and Crimp: For non-permanent connections, such as when using jumper wires with a breadboard or connecting to Arduino or Raspberry Pi headers, crimping can be a reliable alternative. Use a crimping tool to ensure a secure mechanical connection.
  • Heat Shrink Tubing: Whenever possible, use heat shrink tubing to cover and insulate soldered or crimped joints. This not only prevents short circuits but also strengthens the joint by reducing movement.
Wire Harnesses and Cable Management
As your circuits grow in complexity, managing wires can quickly become a challenge. Neatly organized wires reduce the risk of tangling, accidental disconnections, or interference between signals. Here are a few methods to manage your wiring effectively:
  • Wire Bundles: Group wires that follow a similar path using zip ties or twist ties. This will keep your wiring organized and easy to follow. For example, you might bundle together all the power and ground wires running from your microcontroller to various components.
  • Wire Harnesses: A wire harness is a bundle of cables that have been neatly organized and insulated. If your project has multiple connections between different boards or external sensors, consider using a pre-made harness or creating your own with cable sleeves. This helps with both aesthetics and reducing interference between data lines.
  • Labelling: For particularly complex circuits, consider labelling the ends of your wires, especially if they run over long distances or if you're using multiple wires of the same colour. Labelling simplifies troubleshooting when working with multiple control or communication lines.
Avoiding Common Wiring Mistakes
Messy wiring is a leading cause of short circuits, component failure, and difficult debugging. Here are a few common mistakes to avoid:
  • Loose Connections: Ensure that all connections are secure, whether they’re soldered, crimped, or plugged into a header. Loose wires can cause intermittent failures or disconnect during operation.
  • Crossing Signal Wires: Avoid running power and signal wires in parallel over long distances, as this can cause electrical interference. If possible, use separate paths or different layers of a project enclosure for power and signal wires.
  • Overcrowding Headers: In Arduino and Raspberry Pi projects, you may be tempted to plug multiple jumpers into a single header pin. While this can save space, it increases the risk of loose or crossed connections. Instead, consider using a breadboard or a GPIO breakout board to expand the available pins.
Polarity and Wire Safety
​
As with any electronic project, maintaining the correct polarity is essential, especially when dealing with higher voltage systems or sensitive components. Always double-check that positive and negative wires are connected correctly.
  • Reverse Polarity Protection: Some projects may require reverse polarity protection to prevent accidental damage if power is connected the wrong way. This can be achieved using diodes or specific circuitry to ensure the current flows only in the correct direction.
  • Wire Gauge: For projects involving higher currents, such as motors or power-hungry devices, make sure to use thicker wires that can safely handle the current. Using wires that are too thin can result in excessive heat build-up or even cause the wire to melt.

By following these best practices, your projects will not only look more professional but also be safer, more reliable, and easier to troubleshoot. Organising wires carefully and using a standard color-coding system will pay off in the long run, especially as your projects become more complex.
Picture
SUGGESTIONS
We would love to hear from you
SUBSCRIBE 
To enjoy more benefits
We hope you find this site useful. If you notice any errors or would like to contribute material then please contact us.