Introduction: How To: Power (with Intel Edison)
At the core of any electronic project is knowing how to power it and how long it will last. This Instructable focuses on how to power digital electronic projects that take low voltage. Basic components and principles will be gone over, such as AC vs. DC power, circuits in series and in parallel and Ohm's Law. In addition to being introduced to these fundamental topics, you will also learn how to power the Intel Edison with Arduino and Mini breakout.
Step 1: AC Vs. DC
There are two different kinds of power signals that you can work with when powering a project, alternating current (AC) and direct current (DC). As the names suggest, it has everything to do with how current flows. Direct current flows in one direction, while alternating can flip it and reverse it, changing directions at timed intervals.
This Instructable is geared towards low voltage DC powered projects using a microcontroller and other digital components. Still, understanding AC is important and can be used to power your DC project too.
AC is available through wall outlets in the United States at 120 volts, it can be found clocking in at 220 – 250 volts elsewhere. This is a lot of power! This kind of juice will give you a good jolt if you touch ground and power at the same time, creating a short. This can be very harmful to a person, so be careful when working with AC. Most microcontroller projects will need 5V or 3.3V, not the hefty 220 volts coming from the wall outlet. To fix this, use a converter that plugs into the wall and outputs a steady voltage and current out of a barrel plug that is appropriate for your project.
DC is mainly obtained through batteries, read more about those in the next step.
Step 2: Ohm's Law
Ohm’s Law is made of 3 equations that states the relationship between current, voltage and resistance.
V = voltage
I = current
R = resistance
V = I x R
I = V/R
R = V/I
The triangle diagram is a easy visual reminder of the equations. this is how it works.
- Voltage is on top, above the dividing line
- Resistance and Current is below the dividing line and get multiplied
- Cover up what you want to know and read what is left
One common way to use Ohm's Law is to find out a value of a current limiting resistor. For example, you want to install an indicator LED into the new guitar pedal you just got. You circuit will look something like the one above.
LEDs have a voltage rating and a current rating. The voltage rating is how much the LED is going to use up or “drop”, this can be annotated by different abbreviations, such as Vf (meaning forward voltage). The dropped voltage can range from 1.8 - 3.3 volts, dependent on the color of the LED. Used in the example circuit here is the typical forward voltage of 2V and rated current of 20 mA.
We can’t hook up the 9V battery straight to the LED without it burning up and out. We need a resistor to resist the power. That's where Ohm's Law comes in.
First, subtract 2V (voltage drop from the LED) from 9V to get 7V.
We now know we need the resistor to take 7 volts, leaving 2 for the LED. From the LED current draw, we know our current value to use is 20 mA. In order to use this in the equation, we need to covert milliamps to amps : 20 mA becomes .02 amps.
R = 7(volts)/.02(amps)
350 ohms = 7/.02
Our resistor needs to be a value of 350 ohms. If the result isn’t a standard value resistors come in, round up to the nearest one.
Use the other two equations to find the current a component is drawing or how much voltage something is dropping. As long as you have 2 of the values in either equation, you can determine the third.
Step 3: Parallel Vs. Series
When connecting electrical components to one another, there are two basic ways, in parallel or in series. Let's take a look at what happens when you wire up LEDs and batteries in both configurations.
Say you have 4 LEDs that you connect end to end, the positive of one to the negative of the other, continuing down the line. You will end up with one positive and one negative lead, which then gets connected to a power source. Being arranged in series, end-to-end, routes the power through every LED. Traveling through multiple LEDs causes voltage to drop with each one. If it takes 2.2V to power one LED, a 3V will do the trick with one, but with two in series, they will not light up since 2.2V x 2 = 4.4V, which can not be provided. With current it's different, when LEDs are put in series, the current draw is the same as one LED and is not multiplied by how many LEDs there are.
When connected in parallel, all the LED negative terminals run along the negative bus of the battery, and all the positive terminals run along the positive. Running in parallel with each other and sharing the same power buses means that they all receive the same amount of voltage. You can now use a 3V battery to run the four LEDs. While in parallel, the current is the one that gets multiplied this time. The 4 LEDs will take 3V, but drain the battery faster.
Putting batteries in series is very handy when you need more voltage than what one battery can provide. This is how large voltage batteries are made, if you were to open one up you would find smaller batteries connected in series inside. When connected end to end, voltage adds up, but the current (capacity), of the battery stays the same.
Say you need your 3V project to last longer, what can you do? If you have multiple 3v batteries, running them in parallel can fix the situation. Connect all positive terminals of each battery together and doing the same with the negative terminals. This adds up the capacity of each battery, while keeping voltage the same.
Step 4: Powering a Project
Below are the most common ways to power a project.
A project can be powered by your computer via a USB cable.
Apple computers state a USB 1.1 or 2 port can supply up to 500 mA (Milliamps) at 5 V (Volts). Ones with USB 3 can supply up to 900 mA (milliamps) at 5 V (Volts).
On Windows 7 machines, the port can supply up to 500 mA at 5V. You can check to see how much power your peripheral is taking up by going to Device Manager, expanding the Universal Serial Bus controllers option and clicking on the power tab in the pop-up window. Here, you will see what devices are connected and how much current they draw.
If your project exceeds the maximum amount of current allowed through the USB ports, a warning will pop up on your screen and the port will temporarily shut down.
Batteries supply DC voltage with a finite amount of capacity. Most commonly you will be using Lithium Ion, Lithium Polymer or Alkaline batteries. If one battery isn't able to supply the operating voltage or current needed, they can be put in series or in parallel, multiplying either the current or voltage. Read more on this in the Parallel vs. Series step.
With batteries, you need to look at the voltage and the capacity. This is usually printed on the package or the battery itself, the capacity is sometimes more hidden. You can look up the datasheet for the particular battery you are using, or use a multimeter on the Ampere setting. The capacity of a battery is labeled in milliamps per hour (mAh) or ampsper hour (Ah). There are 1000 milliamps in 1 amp. You can roughly figure out how long your circuit will run once you know how many milliamps it draws.
For example, if you have 4 LEDs that take up 20 mA each running in parallel, they will take up 80 mA all together. The microcontroller consumes current as well, say it consumes 12 mA, total these together to get 92 mA. Say the battery has 2000 milliamps, the equation would look like this.
2000 / 92 = 21.74 hours
Note that this is a rough estimate, when powering a project, voltage and current can be lost in various places. This is a downside of voltage regulators, when they regulate the input power some is lost and is dissipated as heat. Current draw for components are sometimes listed at their highest, so if a bluetooth module sleeps, it will draw less current than when it is awake and ready to transmit data. It's behavior may depend on sporadic human interaction or the timing in your program. So, you can see that there are many factors in power usage and estimating operating time. Which is why one of the best ways may be to allow the project to run in it's environment and time how long it takes for the battery to completely drain.
To find out what voltage and current values are being used at a specific part of a circuit, us a multimeter.
Wall Converter or Wall-wart
A wall-wart is plugged into a wall outlet and converts high AC voltage to low DC voltage and regulates the current. Printed on the wall wart, two important pieces of information can be found. You can find the output voltage and current printed on the part that plugs into the wall. Most likely you will want 5 volts at 2 amps.
INPUT : 100-240Vac 50/60HZ
OUTPUT : 5Vdc 2000mA
The input is the range of AC voltage it can take, which is then converted to the output voltage and capacity.
For most converters, a barrel plug can be found at the end which can be directly plugged in to a microcontroller. Before you do, use a multimeter to read the voltage that comes out of the converter. The voltage can be much higher than what is marked and can damage your circuit. If it is, a voltage regulator can be used. Learn more about regulators in the next step.
Variable Bench Power Supply
These are found in electronic labs and are an essential tool if you are building and testing circuits often. A bench power supply can vary their output of current and voltage, allowing you to adjust to the specific value needed for a project. The range of the output depends on the kind you buy, most likely it will go from 0Vdc - 50Vdc and have a maximum current setting, making sure your circuit does not draw more than is needed.
Step 5: Regulating Voltage
Voltage regulators are solid helpers, they are easy to use and can be essential when powering parts of a circuit. They take an input of voltage, step it down and maintain a constant voltage level. Common ones used for DC projects maintain 3.3, 5, 9 and 12 volts.
You can usually find the voltage level printed on the package included in it's part number. For example, the regulated pictured here is a 7805, the 5 indicates that it maintains 5 volts.
LM7809 : 9 volts
L7812: 12 volts
LD1086V33 : 3.3 volts
Regulators have 3 terminals, one that takes the input voltage, one that gets grounded and one that outputs the new regulated voltage.
There are negative and positive voltage regulators, make sure you know which one you are using. All the regulators listed about or positive voltage regulators.
Power fluctuates and doesn't always flow consistently. This can be especially true when using a wall-wart, which will be labeled with an output of 5V, but if measured with a multimeter could read up to 8v. This additional amount of voltage can damage your circuit. Before powering up your microcontroller with a wall-wart, run it through a regulator to make sure you don't go over the recommended operating voltage.
Another thing they are superb for is stepping down 5V to 3.3V if you are using a 3.3V component with a 5V microcontroller.
The downside to voltage regulators is when they regulate the input power, some dissipates as heat and is lost.
Step 6: Powering the Edison : Mini Breakout
For a definitive explanation on how to power the Mini breakout Edison board, check out the Edison Breakout Board Hardware Guide here.
There are many ways to power the Edison with Mini breakout. You can hook up a rechargeable Lithium-Ion battery, with a thermistor or without. If without, check out section 2.1 of the hardware guide.
There is a main power input that can take 7 - 15Vdc and a footprint to solder a 2.5mm power barrel jack. These two sources feed to the charging circuit that will charge the Li-ion at a 4.2V rate. The Edison system runs between 3.15V - 4.5V, when running analog sensors, the high reference voltage will be 4.5V, be aware of this when calibrating.
Step 7: Powering the Edison : Arduino Breakout
For a definitive explanation on how to power the Mini breakout Edison board, check out the Edison Arduino Breakout Board Hardware Guide here.
If you are familiar with the Arduinio UNO, you will already recognize some of the power options, but there are still some differences and some additions to be aware of.
Here are some features and facts that I have taken from the hardware guide and consolidated.
The board can be powered through:
- Vin, where external power at 7 - 17Vdc can be hooked up. Use a source that supplies no more than 1 Amp.
- Barrel DC power jack that can take 7 - 17Vdc. Use a adapter that supplies no more than 1 Amp.
-For low power applications (those shields running off 3.3 V) a lithium ion battery (3.0 to 4.3 Vmax) can be attached to J2
- A USB cable via micro USB connector J16
- 3.3V output
- 5V output
- Ground (there are 3 terminals)
- IORef, reference voltage. To change the reference voltage, select 3.3 or 5V with the jumper. The default position is 5V.
- ARef, ADC reference voltage. Select between IORef or ARef with jumper 8 on board.
The Arduino breakout can be powered through the Vin pin, via USB or through the barrel jack.
We have a be nice policy.
Please be positive and constructive.