I explained an idea I had for a Halloween animation using
pumpkins, LEDs, microcontrollers, and a PIR sensor in my last post. Making all
these items work with each other sounds all well and good, but none of them
will even turn on without a stable power supply. Being a power electronics guy
I am all about power supplies and efficiency, which is why I am dedicating this
post to telling you how to get a power solution for your next project that just
works…as all power supplies should. I will show you an example using my
Halloween animation project.

But there is a problem with this approach. Each
microcontroller will require its own 5V supply rail and there are four of them.
Running four 5 volt power supplies off some extension cord is really impractical
and a mess aesthetically. Instead, the simple solution is to use batteries to
power each of the devices. Go do a Google search for “5V battery” and see what
you can find for me. I will be here when you get back.
*****************************************************************
Well that was fun. I’m guessing your search turned up
nothing and now you have come back here looking for answers. Suckers. The truth
is batteries do not come in all types of voltages because their performance is directly related to their cell chemistries.

Now is about the time I tell you that if you try to use a
higher voltage and count on the voltage dropping over a usable range then you
will likely blow up your device. So how is it possible then to get to voltage
to stay at 5V despite battery discharge when dropping too low shuts everything
down and going too high blows everything up? While there are many answers to
this question, the one I must shamefully recommend is the voltage regulator.

Secondly, voltage regulators have what’s called a “dropout
voltage” rating, which tells you the minimum input voltage above your desired
output. For instance, the LM7805 pictured above is one of the most famous and widely used
regulators on the planet (look into the LM317 for another). It provides a
stable 5Vdc output with input voltages up to 40Vdc and a typical dropout
voltage of about 2 volts (for future reference, this figure can vary with
loading conditions). That means that if you want an output of 5 volts, your
input voltage must be at LEAST 7 volts. Certain regulators can operate down to
a dropout voltage of 300mV or lower. We creatively call these regulators “Low-dropout”
regulators, or LDOs for short.
Since most voltage regulators rely on feedback loops to
control the output voltage, you will likely need to add some bypass capacitors
on the output. This can sometimes be a hidden cost associated with voltage
regulators, but they are usually not a big problem. Make sure to check out the
datasheet for the regulator in question because often times it will tell you
what size capacitor you need. The image below shows the sample circuit configuration for getting a stable 5 volt output from the LM7805, and you can see that they recommend using capacitors on both the input and output pins.
I will show you how I chose the regulator I am going to use in my Halloween project in another post. This entry was meant to be a high level look at
how to get common voltages for your next project (3.3V, 5V, 9V, 12V). If you need something other
than 5V, never fear because lots of regulators are adjustable so you can
configure components around it to get the output voltage you want. Again, the
part's datasheet should give you some information on how it can be done. Datasheets
are an engineer’s best friend.
0 comments:
Post a Comment