Each Group Collect
- Digital Multimeter
- Variable Voltage Power Supply
- Bana Plug Leads
- Resistors
- DC Motor
What is Electricity?
A general understanding of electricity and the rules that determine how it flows and how it can be controlled are crucial to quickly prototyping your designs. These resources cover the fundamentals of working with electricity.
- Tom Igoe: Understanding Electricity
- Sparkfun: Voltage, Current, Resistance and Ohm’s Law
- ITP: Electricity, the Basics
- Voltage is the difference in charge between two points.
- Current is the rate at which charge is flowing.
- Resistance is a material’s tendency to resist the flow of charge (current).
Water analogy from Sparkfun
Voltage = Pressure in system
Current (Amperage) = Amount of Flow
Resistance = Resistance to Flow
V = I * R (voltage = current * resistance)
I = V / R (current = voltage / resistance)
Solve for LED / Resistor Combo
We know the ideal forward voltage (Vf) and current (I) of the LED.
Target Vf = 3.3v
Target I = 20mA (0.02A)
V = I * R
R = (Vs – Vf) / I
Exercise 1: Learn the Digital Multimeter (DMM)
Sparkfun: How to Use a Multimeter
- Set up a simple circuit on a breadboard with an LED, a resistor, and the variable voltage power supply:
- Set the power supply to 5V
- Use the the DMM to measure voltage at different points of the circuit
- Notice the amount of current being used by the power supply
- Insert the DMM into the circuit and measure the amount of current (see if it matches what the power supply says)
- What happens if you change the resistor?
- Add a switch or button
- Draw the [circuit diagram](https://learn.sparkfun.com/tutorials/how-to-read-a-schematic) on the table
What is Arduino?
A simple microcontroller and software combo developed to help designers, artists and non-engineers rapidly prototype with electronics.
Some things to remember:
- Analog Pins are for reading only (0v – 5v)
analogRead(pinNumber)
returns an integer value between 0 – 1023- Digital Pins can be
INPUT
orOUTPUT
- digital pins can supply a low-current (100mA) 5v supply in output mode:
digitalWrite(pin, HIGH/LOW);
- digital pins can read the state of that pin, as either
HIGH
orLOW
(5v or 0v):digitalRead(pin);
- digital pins can supply a low-current (100mA) 5v supply in output mode:
- You can run the arduino WITHOUT the USB cable attached (only a 5v-24v barrel jack)
- You can also power from the Vin and GND pins.
Exercise 2: Set up Arduino & Blink
- Download the Arduino IDE
- Follow the Getting Started guide for the Arduino UNO (word for word!)
- Run the Blink! example sketch
- Open Examples > Basics > Blink
- Plug your Arduino into the computer
- Choose your board: Tools>Board
- Choose the correct port: Tools>Port
- Click the check icon (verify)
- If no errors, upload to the arduino
Exercise 3: Reading Data & Graphing it
- Find a sensor (Potentiometers are a good one)
- Attach it to the Analog pins of your Arduino
- You may need to find a diagram/datasheet/instructions on the internet
- Graph the output in either Max or Processing (or both!)