Electronics Training Course 1

Embed Size (px)

Citation preview

  • 7/30/2019 Electronics Training Course 1

    1/32

    Beginning Embedded Electronics - 1byNate| June 19, 2008 |88 commentsSkill Level: Beginner

    Lecture 1 - Background and Power Supply

    This is a series of lectures written for those with mild electronics background (aka Sophomore in

    Electrical and Computer Engineering) to learn about the wild world of Embedded Electronics. I

    assume only that you know what electricity is and that you've touched an electrical component.

    Everything else is spelled out as much as possible. There is quite a lot here so take your time! It is

    also my intention to get book-hardened EE's students to put down the calculator and to plug in an

    LED. Remember, if it smokes, at least you learned what not to do next time!

    You can get all the parts for this lecturehere.

    Sorry for the confusion. When these tutorials were written and photographed, we used the

    ATmega8. We now carry the newer ATmega328. You will find all ATmega328 information in the

    following pages, but the pictures will show an ATmega8.

    What's a Microcontroller?

    You may know what an OR gate is. An OR gate is a logic gate that takes two inputs and controls an

    output. You may have played with these types of gates, even possibly a DIP packaged OR gate

    with 4 OR gates built into it. This DIP package required a power pin and a ground pin. Electricity

    flowed through the IC and allowed it to operate. You may not be sure how the IC was built, butyou understand that if you change the inputs, the output changes. You can do this by tying the

    inputs to either power (also known as VCC) or ground (GND). You probably played with one of

    the DIP ICs in a breadboard. If any of this is completely alien to you, don't fret! We'll try to ease

    you into it.

    A microcontroller is the same as an OR gate. You have some inputs, you have outputs. The crazy

    thing is that a micro runs code. Machine code to be specific. For instance, with a little bit of work,

    you can monitor the input of two pins A and B. And based on those inputs, you can control an

    output pin C. So to replicate an OR gate:

    if (A == 1 || B == 1)

    {

    C = 1;

    }

    else

    {

    C = 0;

    https://www.sparkfun.com/tutorials/57https://www.sparkfun.com/tutorials/57http://www.sparkfun.com/users/7185http://www.sparkfun.com/users/7185http://www.sparkfun.com/users/7185https://www.sparkfun.com/tutorials/57#commentshttps://www.sparkfun.com/tutorials/57#commentshttps://www.sparkfun.com/tutorials/57#commentshttp://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.sparkfun.com/commerce/product_info.php?products_id=8373https://www.sparkfun.com/tutorials/57#commentshttp://www.sparkfun.com/users/7185https://www.sparkfun.com/tutorials/57
  • 7/30/2019 Electronics Training Course 1

    2/32

    }

    It's C code! You can code up all sorts of different applications, compile code, load it onto a micro,

    power the micro, and the code runs. Very simple! Microcontrollers are used in all the electronics

    you take for granted such as your microwave, TV remote, cell phone, mouse, printer, there's over

    150 microcontrollers embedded into new cars! There's one waiting for you to depress the brakes

    (BRAKES == 1) and for the tires to lock up (LOCK_UP == 1). When this happens, the micro

    releases the brakes, and you have ABS (anti-lock brake system).

    In the old days, microcontrollers were OTP or one-time-programmable meaning you could only

    program the micro once, test the code, and if your code didn't work, you threw it out and tried

    again. Now micros are 'flash' based meaning they have flash memory built inside that allows their

    code to be written and rewritten thousands of times. I've been programming micros for years and

    always burn out the microcontroller far before I hit the limit of flash programming cycles.

    Flash micros are different than computers and RAM. Computers require tons of power andcomponents to get up and running. Computers run HOT. Computers take forever and a day to

    boot. Micros are on and running code within milliseconds and if they're warm enough you can

    feel heat coming off of them, something is verywrong and you've probably blown the micro. Oh -

    and micros cost about $2.

    Now back to that OR gate IC. It had a bunch of pins, all dedicated to being either inputs or

    outputs of the various built-in OR gates (4 gates in one package = 8 inputs, 4 outputs, 2

    power/gnd pins). 14 pins of fun. Now with a micro, the most basic pin function is GPIO - general

    purpose input/output. These GPIO pins can be configured as an input or an output. Very cool.

    Each input pin can be monitored and acted upon. Example:

    if (PORTC.2 == 1)

    then do something...

    Each output pin can be pushed high or low. Example:

    while(1)

    {

    RB3 = 1;

    delay_ms(1000);

    RB3 = 0;

    delay_ms(1000);

    }

  • 7/30/2019 Electronics Training Course 1

    3/32

    Guess what that code does? It toggles a pin high/low every 2 seconds. Fancy right? This is the

    'Hello World' of the microcontroller world. It seems trivial, but by god when you've been trying to

    get a micro up and running after 5 hours of tearing your hair out and you see that LED blinking

    for the first time, it's just glorious!

    What types of microcontrollers are there and how do I get one blinking?

    Here's a very shallow breakdown of the micros in my world:

    PIC- This is the classic micro from Microchip. Very simple, very proven, but it lacks

    many of the features that other mfg's are building into their chips. This is a big deal for

    me. I was a die-hard PIC person for years and I've started to see the limits of PICs and the

    benefits of other micros!

    AVR- This is basically a direct competitor of PICs. They do everything a PIC does, but in

    my new opinion, better, faster, cheaper, and simpler.

    MSP- These are very good micros by Texas Instruments (TI), not as beefy as AVR orPICs. However they truly excel at low-power applications. More on this later, but imagine

    running a complete system on one AA battery for 5 years. This is in the realm of nano-

    amp current consumption. Crazy!

    ARM- Why are all these three letters? I don't know actually... ARMs are the new kids on

    the block and they are huge. Very powerful, very low-cost, they are taking over the world

    but can be really intimidating if you've never played with a micro before.

    8051- The '8051 core' was the de facto standard in 8-bit (and 4-bit!) microcontrollers.

    Developed by Intel in the 1980s, it still seems to be the instruction set they love to teach

    you in college. They are based on archaic, but field proven instruction sets. Very old tech

    in my humble opinion, but these ICs have been significantly improved over the years(now Flash based, ADC, SPI, etc.).

    68HC08/11- Another very common instruction set developed by Motorola. Extremely

    popular, and a micro commonly taught at university, it's the microcontroller I love to

    hate. These original micros often lack on-board RAM and flash based memory.

    Google any of these for more info. I have chosen the ATmega168 as the learning IC of choice.

    Why?

    20 MIPs (million instructions per second!) is powerful enough to do some really cool

    projects

    It's cheap! $2.13 currently

    It's got all the goodies under the hood (UART, SPI, I2C, ADC, internal osc, PWM, kitchen

    sink, etc)

    16K of program memory is enough for almost any beginner project

    The tools are free! (C compilers for many of the other micros cost a lot of money)

    The programming and debugging tools are low cost ($20 will get you started)

    http://en.wikipedia.org/wiki/PIC_microcontrollerhttp://en.wikipedia.org/wiki/PIC_microcontrollerhttp://en.wikipedia.org/wiki/Atmel_AVRhttp://en.wikipedia.org/wiki/Atmel_AVRhttp://en.wikipedia.org/wiki/TI_MSP430http://en.wikipedia.org/wiki/TI_MSP430http://en.wikipedia.org/wiki/ARM_architecturehttp://en.wikipedia.org/wiki/ARM_architecturehttp://en.wikipedia.org/wiki/8051http://en.wikipedia.org/wiki/8051http://en.wikipedia.org/wiki/Freescale_68HC11http://en.wikipedia.org/wiki/Freescale_68HC11http://en.wikipedia.org/wiki/Freescale_68HC11http://en.wikipedia.org/wiki/8051http://en.wikipedia.org/wiki/ARM_architecturehttp://en.wikipedia.org/wiki/TI_MSP430http://en.wikipedia.org/wiki/Atmel_AVRhttp://en.wikipedia.org/wiki/PIC_microcontroller
  • 7/30/2019 Electronics Training Course 1

    4/32

    With a little work and probably $40 worth of parts, you too can get an LED blinking. As with any

    new hobby (also known as a drug addiction), the extra cost of 'goodies' can grow very quickly.

    You want to play microcontrollers today?

    With any IC, you need to power the thing. There are two power connections on basic micros : VCC

    and GND. What the heck is VCC? This is the label for the positive voltage. Don't worry, after a few

    days of this, seeing 'VCC' will become very normal. GND is short for ground. All electrical current

    needs a way to flow back to ground. This can be called 'common' but is often just labeled GND.

    There are thousands of different micros out there, but 5V (five volts) is the typical VCC. 3.3V is

    also typical but you'll also see 2.8V and 1.8V VCCs on more exotic micros. For now, just worry

    about 5V and GND.

    Where do I find this 5V?

    You can get all the parts for this lecturehere.

    You need to hook up 5V and GND to your micro. Your house outlet runs at 110V AC (or 220V for

    many countries). AC = alternating current and is very bad for 5V DC (direct current) micros. So

    you'll need to convert the 110V AC from your outlet to a useable 5V DC.

    Quick note: If you reverse the connection on your micro - bad things happen. Always make sure

    your 5V power supply is connected to the VCC pins and GND to GND. If you reverse this and

    connect 5V to GND on the micro and GND to VCC on the micro, things won't explode, probably

    no smoke, things will probably heat up like crazy, and you'll probably damage your $2 micro. You

    probably will. I did. Many times. Try not to do it.

    Ok! You need 5V. Time to build a simple voltage regulator circuit!

    You can buy something called a 'wall wart'. Don't ask me why they call it that, ask google. A wall

    wart takes a higher voltage and converts it to a lower voltage. DO NOT assume a wall wart labeled

    '5V' will output 5V. This is amajor misconception- I know, I know, faulty advertising. Just hook

    up your multimeter to the barrel plug and see what voltage you read. Probably more like 8 or 9V.

    This will kill your micro so keep reading! For a more detailed explanation check out

    theUnregulated Power Supply Tutorial.

    Let's assume you are using a wall wart with an output of something nice like 9V. Dandy.

    Unfortunately this 9V output is rather noisy - meaning there is a lot of ripple. Ok what does ripple

    mean? You want a DC voltage meaning you want a solid voltage (the opposite of alternating). A

    wall wart uses some cheap tricks to get 110V AC down to 9V DC. So the DC signal coming out of

    the wall wart tends to alternate 100-500mV. Instead of a solid 9VDC, you see a signal that rises

    and falls between 8.5 and 9.5 volts. This 'ripple' can cause havoc with your system, and9V is too

    http://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.sparkfun.com/commerce/product_info.php?products_id=8373http://www.glitchbuster.com/wallwart.htmhttp://www.glitchbuster.com/wallwart.htmhttp://www.glitchbuster.com/wallwart.htmhttp://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=103http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=103http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=103http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=103http://www.glitchbuster.com/wallwart.htmhttp://www.sparkfun.com/commerce/product_info.php?products_id=8373
  • 7/30/2019 Electronics Training Course 1

    5/32

    high (we need 5V!) so we need to pass 110V through this wall wart, and send the 9V through a

    regulator to get down to a clean 5V DC signal. If this all sounds scary - don't worry. After you get

    your 5V power system built, you'll wonder why you were scared in the first place (it's simple, I

    swear).

    The most common regulator is called the LM7805. Why? I dunno. I've never actually touched a

    component with LM7805 stamped on the outside. There's always other letters stamped on the

    outside like 'LM7805' or 'LV78X05' or some such crazyiness. Just know that there are many many

    manufacturers out there and they are all producing the same basic part, with small tweaks to each

    one. What you need is one of these generic parts that is designated as a '5V linear regulator'. If

    you're playing in a breadboard, you'll also want it in the TO-92 or TO-220 package. More about

    packages in a later lecture, just go with it for the moment.

    You've got your regulator in hand, you've got the wall wart. Time to connect them up.

    Here you can see the 'pin-out' of the LM7805. Say 'IGO' in your head and commit this to memory

    (input, ground, output). You'll probably hook up a lot of these. When in doubt, always check the

    datasheet before hooking up a new part - or else be close to the on/off switch! Input is the input

    voltage of anything greater than about 7V. GND is ground. Output is the 5V output pin. Your wall

    wart should have two wires. One is 9V, the other is GND. All grounds need to be connected

    together for current to flow across the system. One more time - connect all grounds. This is the #2

    reason why novii can't get a system to work. For our breadboard, we will be inputting 9V (or

    whatever transformer you've got up to about 15V) and outputting 0V (GND) and 5V to our

    breadboard rails.

  • 7/30/2019 Electronics Training Course 1

    6/32

    We are going to go through a bunch of iterations of the power supply, adding parts as we go.

    Shown above, we have a basic regulator configuration. 9V in, we should see a rough 5V on the

    output.

    Schematic note: The two ground pins are not shown connected. We assume that nets (the

    green wires) of the same name are connected together. Schematics can get big and complex, so

    you won't see all the wires together, but in your breadboard you need to connect all the GND pins

    together. In this case it's the GND wire from your wall wart connected to the GND pin on the

    regulator.

    Cool. But why doesn't the multimeter read 5.000V? Electronics are not that good. The cheap-o

    regulators are +/-5% tolerate meaning you'll see between 5.25 and 4.75V. In practice, you should

    see between 5.1 and 4.9V with most run of the mill regulators. You can of course spend many $$and get tighter tolerances but 5.1-4.9V will work fine for our purposes.

    Now we should be worried about ripple. There is noise coming in the input pin, the regulator tries

    hard, but some of that noise gets onto the output pin. Your multimeter says 5.08V, but that's

    because it's averaging many readings together and showing you only the average. Do you know

    someone with a oscilloscope? If so, show them this tutorial and ask them to show you the noise on

    your 5V rail. With no filtering caps, you could see as much as 200mV of noise.

    Whoa - what's a filtering cap? Filtering capacitors are large bulky capacitors that help smooth out

    ripple. There've been lots of analogies about capacitors so here's another one for ya:

    Capacitors act like water tanks. When your circuit pulls a bunch of water out of the system, the

    capacitor helps hold the voltage up temporarily until the power system can catch up. For example:

    you may live in a city with water and water pressure. If you take a shower you affect the pressure

    in the municipal water system ever so slightly. If everyone turned on their shower and flushed

    every toilet in the city, odds are the water pressure would fluctuate quite a bit! A big water tank

  • 7/30/2019 Electronics Training Course 1

    7/32

    helps minimize these pressure fluctuations. A big cap helps minimize the voltage fluctuations on

    your breadboard.

    Is this something you can see happen? Unfortunately not really. You can probably run your

    system without filtering caps, but it's not good engineering practice. Give it a whirl without caps!

    But when things don't work, you'll wonder if it's the caps, or your code, or your timing, or maybe

    you blew out the sensor. Too many unknowns will make you crazy. My recommendation: just use

    a couple basic caps...

    100uF (one-hundred micro farad) on the input and 10uF on the output. You will use a lot of

    100uF and 10uF around power systems and you will eat 0.1uF (point one micro farad) caps like

    candy around micros. These two caps should smooth the input into the regulator and will smooth

    the output nicely.

    Capacitors cannot deliver their stored energy instantaneously. Larger caps (1ouF and 100uF)

    store more energy, but they react more slowly. The smaller the capacitor, the faster it can deliver

    its stored energy. If you have a large power outage (power dips for 10-100ms), a big cap (100uF

    to 1000uF) will help 'hold up' the falling voltage. A smaller cap (0.1uF) will help suppress higher

    frequency noise and shorter power dips (noise in the 1us to 100us range). Therefore, 0.1uF caps

    are located near the microcontroller to help with short bursts, where 100uF and 10uF caps are

    used on the power rails.

    Now you see the schematic symbol looks a bit odd. What's with + and curved lines? This

    schematic component is indicating that the 100uF and 10uF cap arepolarized. Oh jeebus, what's

    that? Time for a capacitor breakdown:

    Electrolytic caps: These are larger caps capable of storing 10uF to 1,000,000s of farads.

    They are cheap and great for bulk capacitance. They are polarized meaning there is a

    positive pin and a negative pin.

  • 7/30/2019 Electronics Training Course 1

    8/32

    The cap has a minus '-' sign on the cover indicating that pin needs to go to GND.

    Ceramic caps: These are the cheapest and most common cap you'll play with on a

    breadboard. They are NOT polarized so you can stick em in the breadboard any way you

    want. Ceramic caps cannot handle as large of capacitance as electrolytics so you'll need

    both on your breadboard system.

    There are many more different kinds of capacitors but for the sake of your head

    exploding, we won't cover them here.

    Okay - now you need to work through some logic here. You know the positive part of the 100uF

    cap needs to be connected to the input pin, but only the negative pin is marked. Yes it's confusing

    - but you'll get used to it. Negative marked pin goes to ground, the other goes to the input pin.

    What happens if you get them switched? Well here's where things may go poof.

  • 7/30/2019 Electronics Training Course 1

    9/32

    From the left: Bad, good, ugly

    This is what happens when you over-voltage or reverse voltage a polarized capacitor. The middle

    cap is normal. The cap on the left, you can see the top is slightly raised up. This is what happens

    when the electrolyte inside expands. And the cap on the right shows us what happens when this

    pressure is so great, it busts through the metal top. Notice the '+' imprinted into the tops of these

    caps? That imprint is there so that if the pressure does build up, the cap will fail like the unit on

    the right - rather than blowing the top half of the cap across the room.

    This picture was taken from the inside of an old Gateway computer (circa 1999). Gateway had

    used some 'marginal' 1000uF/16V capacitors. The /16V means they are rated to 16V. A 16V rating

    means they can withstand voltages up to 16V but no more. These caps were sitting on the 12V rail

    to smooth out the ripple but obviously they where failing. Gateway was trying to save $0.50 by

    using a capacitor that was too close to the maximum. Manufacturing is not perfect! With any

    production run, the population of capacitors and their tolerance looks like a bell curve. The

    majority of the 16V rated caps can withstand 16V. Some can 18V, even 22V! But the tolerance bell

    curve goes both ways; a small number of the capacitors rated at 16V will fail at 10V, some at 8V.You get a big enough ripple on the 12V line and you could pop the 16V rated cap. This is why most

    engineers talk of 'de-rating' capacitors. If you have a 5V rail, you do notstick a 5V rated cap on the

    rail! A good rule of thumb is to de-rate any capacitor by 50%. So a 12V cap is good to be used on

    6V rail, 24V cap on a 12V rail, etc.

  • 7/30/2019 Electronics Training Course 1

    10/32

    Guess what happens when an electrolytic cap fails like the ones above? They quit working. In

    most cases, they 'fail safe' meaning they won't work as a capacitor anymore butthey won't short to

    ground. The real fun begins when the failure is so bad that the internals fuse together and you get

    a short to ground - then you can have some fun melt downs! In the case of this computer, the

    motherboard had all sorts of bad software failures because the power supply had too much ripple!

    The big filtering caps on the power supply had failed so the 12V was all over the place.

    Similar failures can happen if you reverse the polarization of the cap. If the voltage is low (less

    than around 25V) the cap will probably just be damaged a bit. If you've got a vacuum bell sitting

    around and you want to really cause some damage, ask a trained professional to hook up 10V cap

    backwards to 10,000V. It should instantaneously blow up like a pop corn kernel.

    For your power supply filtering caps, I recommend using a 25V rated 100uF cap (100uF/25V) on

    the input and a 10uF/10V cap on the output. Engineers will tell you to 'derate' the cap by 50%

    meaning if the label says 100V don't trust it past 50V. This is generally good practice. Following

    this idea, our 100uF/25V is good for inputs up to about 12.5V before we should worry that we maypop the electrolytes. Again, not mandatory, just don't expect a 5V rated cap to withstand a 9V

    input.

    Back to our power supply! Don't worry about blowing things up just yet, you should be at low

    enough voltages you won't do any harm. Again, if things heat up/smoke/spark, just unplug or

    turn off the system. Speaking of turning things off - we need a power switch!

    This will allow you to turn on/off the system. Handy. It can get really annoying pulling and

    inserting the power wires to power/kill your system.

    Inside the small black enclosure, is a switch. The switch has three pins. It looks like a see-saw

    inside. The center pin is always connected to the middle of the see-saw and as you slide the switch

    back and forth, the see-saw rocks up and down. Slide the switch forward and the see-saw shorts

  • 7/30/2019 Electronics Training Course 1

    11/32

    from the center pin to the forward pin. Slide the switch back and the see-saw disconnects from the

    forward pin and shorts to the rear pin. We recommend you connect power to the center pin of the

    switch. When you slide the switch forward, power will short to an unconnected pin and do

    nothing (no power to your system). Slide the switch back and the center power pin will short to

    the wire running into your regulator, delivering power to your system (power on!).

    Remember all the warning about reversing VCC and GND and how that is bad? Well if you

    connect your power supply backwards, that's bad. So let's protect ourselves!

    That's a diode (marked D1). A diode lets current flow in one direction (in the direction of the

    arrow) and it blocks current from flowing in the opposite direction. This will allow 9V to flow in

    the right direction, and if you accidentally hook your power supply up the wrong way, it will block

    current from flowing backwards and damaging your system. Is it overkill? Pretty close. But wealways design them into our development boards because we don't know what type of power

    supply you knuckleheads (also known as our paying customers) will plug on to our boards. If you

    plug the wrong type of wall wart onto a board, we want to protect you from yourself.

    There are some down sides to a protection diode:

    All diodes have a voltage drop, meaning 9V on one side will drop to about 8.5V on the

    other. So your 9V wall wart just became 8.5V.

    Diodes have a current rating. If you try to suck 1A (1 amp) through a 0.1A (one hundred

    mili-amp) rated diode, the diode will quickly heat up and fail. For reverse protection, we

    recommend a 1A 1N4001 diode. These are dirt cheap and very common.

    Note that diodes are polarized. They have a direction that you need to pay attention to. Many

    diodes have a band indicating the cathode. What's a cathode? Go google. All you really need to

    know is that the line on the schematic part is the same as the line on the diode. If you can't

    remember which is which, remember 'arrow is for anode'. Cheesy, yes.

  • 7/30/2019 Electronics Training Course 1

    12/32

    So if you want to install this 'reverse protection diode', the 9V from your wall wart goes into the

    end of the diode without the band (the anode). The banded end (cathode) goes into your switch.

    Your switch then goes into the input. Throw the switch and you should see 5V on the output using

    your multimeter. Nifty. But I am tired of using my multimeter each time to check the 5V output.

    There must be a better way! Time to wire in the power LED.

    Light emitting diodes (LEDs) are bits of silicon that light up when current flows through them. Go

    google for the science. As a general rule of thumb, LEDs can have 20mA max current flowing

    through them before they begin to fail.

    So if you hooked up your LED like in the above schematic, it would light up very bright for a split

    second and then burn out. That's cause the LED is a diode and the current will flow from the

    anode (arrow) to the cathode (line) to ground - uncontrolled! The silicon will flow current at

    something like 1 amp for a split second and burn up. To limit this current flow to 20mA, we need

    Ohm's law. Yea, the book worms in the room suddenly perked up:

    V = IR (this is Ohm's law)

    If we have 5V, and we only want 20mA flowing through the LED:

    5V = 0.02 * R

    R = 250 Ohm

    Now this is not completely true because the LED has a forward voltage drop, but don't worry too

    much about that. Hooking up LEDs is very common with micros. All you need to remember is

    that you're going to need to limit the current. The most basic way to do this is with a resistor. 220

    Ohms will work (LED will be brighter), 330Ohm is also good (LED a bit dimmer), 1K (1000) will

    work as well. 220, 330, and 1K are more common resistor values.

    I highly recommend you get your hands dirty. Hook up an LED to a 1k resistor, then a 330, then a

    220, 100, 50, then finally blow the thing up by hooking it with no resistor. That was fun right?

  • 7/30/2019 Electronics Training Course 1

    13/32

    Good. You had a back-up right? Once the bit of silicon inside the LED is burned out, it is no good

    and the LED can be thrown away.

    Eagleschematic/PDF

    Our final power supply circuit. It seems like a lot of work, but once you set this up on your

    breadboard, you might never take it off. This is the basis for all things micro. The input voltage

    may change, the output voltage may change (to 3.3V for example), but the basics are all there. Flip

    the switch and you should have a nice 5V rail and an LED letting you know that everything is a-

    ok.If the LED does not light up, that means that something else on the 5V rail is sucking so much

    current that the LED cannot light up. This is a very strong indicator something is wrong. If you

    turn on your system and the Power LED does not turn on, immediately turn off the

    system and check your wiring.

    You may be wondering if the resistor/LED order matters. It does not. The resistor can come first

    and then the LED or as shown. Either configuration will correctly limit current through the LED.

    If you think you may have blown up your LED then your LED will never turn on. You may want to

    check your power system with a multimeter instead.

    Good, you've made it this far. Now for some technical info about ripple/noise and why it's bad.

    If you've got major ripple on your power rail, say 500mV or more, this can cause your micro tolatchup. This means that it was running fine at 4.8V, but at 4.3V it's not happy and will go into an

    unknown state. When the rail returns to 4.8V (because the ripple is bouncing the rail up and

    down), the micro goes from unknown to possibly latching up or freezing up. This is pretty rare

    these days because the chip manufacturers have done a good job of internally protecting against

    this, but in general, ripple is bad.

    http://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.ziphttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.ziphttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.ziphttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.pdfhttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.pdfhttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.pdfhttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.pdfhttp://www.sparkfun.com/tutorial/BeginningEmbedded/ATmega8-RS232.zip
  • 7/30/2019 Electronics Training Course 1

    14/32

    Say you've got 500mV of ripple on your system and you're doing analog to digital conversions off

    of a temperature sensor. The temp sensor has an output pin that will output an analog voltage

    that will vary 100mV for every 1 degree C. So at 25 degrees C (room temperature) the sensor will

    output 2500mV or 2.5V. If your micro is doing analog-to-digital conversions on this signal, it has

    to compare what it 'thinks' is a solid power rail of 5V against this changing analog signal from the

    temperature sensor. Well if your 5V 'solid' rail has 500mV of ripple, the micro doesn't know this,

    and will report a regular 2.5V reading as varying between ~3.0V (3000mV = 30C) and ~2.0V

    (2000mV = 20C). This is wildly bad. You need a good 'clean' power rail if you are doing anything

    with analog signals.

    Now some notes and photos on breadboards:

    Go readTom Igoe's breakdownof the breadboard. In short, the power rails (the red/blue rows)

    are connected internally. The columns within the main area of the board are interconnected. Soyou can insert a wire into one hole and it will be electrically connected to a neighboring hole

    (vertical connections for the numbered columns, and horizontal connections for the blue/red

    power rails).

    Historically, the blue rail or the horizontal row of holes next to the blue line is 'GND' or ground.

    You can connect all the ground pins of all your components to this rail. Similarly, the red rail is

    for VCC. In our case, this is 5 volts.

    http://www.tigoe.net/pcomp/code/circuits/breadboardshttp://www.tigoe.net/pcomp/code/circuits/breadboardshttp://www.tigoe.net/pcomp/code/circuits/breadboardshttp://www.tigoe.net/pcomp/code/circuits/breadboards
  • 7/30/2019 Electronics Training Course 1

    15/32

    Power jack, switch, LM7805, power LED

    Here you can see power from the barrel jack being delivered to the slide switch, and then to the

    input pin of the v-reg. When the switch is thrown to the on position, the yellow LED turns on.

    I cheated a bit.

    Do you see that odd thing in the upper right corner of the picture? That is my wall wart plugged

    into a DC barrel jack. Most wall warts are terminated with a round connector called a 'barrel'. The

    outside metal sheath is ground, and the inside metal is 9V. The two metal contacts are isolated.

    The DC barrel jack accepts this wall wart barrel (wall wart barrel slides into the jack with some

    friction to hold it in place). I don't like hacking the ends off power supplies and inserting the bare

    wires into a breadboard. Having energized bare wires bothers me. If the wires get pulled out of

    the breadboard because you kicked out the power cord, you'll have some tense moments until you

    get the power brick unplugged. So I soldered some short leads to the barrel jack so that I can

    plug/unplug my power cable from the breadboard. Easier to transport.

    See the orange wire at the end of the barrel jack? That pin inside the DC barrel jack connects to

    the center of the wall wart barrel. The center of our wall wart barrel connectors are '+' or 'hot' or

    '9V', whatever you want to call it. So the end of the DC barrel jack is soldered to an orange wiring

    meaning it is '+'. This orange wire is then connected to the center pin of the power switch.

    All ground connections are connected together. You will see a small black wire underneath the DC

    barrel jack. This is the pin that connects to the outside sheath of the wall wart barrel. This is the

    ground connection on the wall wart. This small black wire connects the ground of the wall wart to

    the ground on the breadboard.

    I did not install a reverse protection diode. I *only* use center positive power supplies so I know

    I'm safe. If you do anything similar, check your wall wart carefully with a multimeter before doing

    any testing.

    Note: Our breadboard will have 5V and 0V rails. The blue rail is GND (considered 0V). Red is

    VCC (or called 5V).

    Note on LEDs: LEDs are a polar device meaning you've got to hook them up in the correct

    direction. Light emitting diodes (LED) have a cathode and an anode. How do you tell the

    difference? Imagine the schematic element:

  • 7/30/2019 Electronics Training Course 1

    16/32

    An LED

    Do you see the arrow? Do you see the flat line? A is for arrow. A is for anode. The physical LED

    will have a flat side corresponding to the flat line (the cathode) in the schematic picture. And

    there you go! When connecting an LED, you know that diodes only pass current in one direction

    (from anode to cathode - in the direction of the arrow!) so the flat side of the LED needs to be

    connected to ground some how (usually through a resistor first) and the other side (remember

    arrow) is the anode and needs to be connected to power for current to flow. If you hook it up

    backwards, it won't turn on, and you might damage the LED but probably not. Just verify that

    you've got 5V on the correct rail and then flip your LED around if need be.

    Power supply with 10uF and 100uF caps in place

    Note the polarization of the caps. The larger 100uF cap is directly connected to the Input and

    GND pins of the v-reg. The '-' sign is connected to the ground pin. The smaller 10uF is connected

  • 7/30/2019 Electronics Training Course 1

    17/32

    on the power rails. The '-' sign (in white) is connected to ground, the opposite leg is inserted into

    the '+' rail. The power LED is on!

    Note: The center pin of the wall transformer is connected to the red wire on the rear of the barrel

    jack. This short wire is then routed by another wire to the slide switch. Do not connect this center

    pin/9V source to the power rail on your breadboard!

    The slide switch has three legs. The center pin is considered the 'common' pin. If the switch is

    thrown to the right, there is a connection from the center pin to the right pin. Slide it to the left

    and a connection to the left pin is made. When dealing with power, we want the raw voltage (9V

    in our case) delivered to the center pin of the switch. When I slide the switch to the left (as

    pictured above), current is allowed to flow from the center pin to the left pin and on to the voltage

    regulator. When I slide the switch to the right, the center pin is connected to the right pin (which

    is not connected to anything). In this state, current does not flow anywhere and the breadboard

    remains powered down. Voila! We have a power switch.

    Power LED is not lighting!

    This picture is key. When I initially wired up this circuit, I flipped the switch and the power LED

    didn't light. That was VERY bad indicating there is a massive short somewhere. Even the good

    guys screw up now and again. Whip out your trusty multimeter and start probing in continuity

    mode.

    Quick note: I highly recommend you purchase a multimeter with a 'continuity' feature built in.

    This mode allows you to 'tone' out circuits. In this mode, if you touch the two probes together, you

    should hear a tone indicating that there is a direct connection between one probe and the other

    (obviously - you have them touching!). This feature is used countless times during trouble

    shooting. In the above example, by probing from one GND rail to another, I noticed that I could

  • 7/30/2019 Electronics Training Course 1

    18/32

    not get a tone. Therefore, there was a break in the circuit somewhere which lead me to realize the

    break is in the rails.

    If you've got a medium sized breadboard such as the one shown above, you'll notice something

    horribly odd. The various holes of the power rails are not connected!

    The yellow lines show what holes are inter-connected and where the breaks occur

    There is a reason why the power rails are broken. If you have a breadboard with multiple and

    different power rails, you cannot share them on the same row of holes. So modern breadboards

    break the rails up so that you can isolate different parts of your circuit. For example, if you were

    building a really complex design you may need to have 5V and 3.3V on the same board. Because

    the rails are isolated from each other, you could just use various strips around your breadboard to

    be designed at 5V, 2.8V, etc. For the purposes of this tutorial (and for almost all breadboarding)

    we assume that you'll only be using 5V and GND. Therefore, we need to use short jumper wires to

    interconnect all the isolated rails, forming one continuous 5V rail and one continuous GND rail.

    When I first wired up my power supply, I only had the long black/red jumpers on the right side of

    the board, but didn't have the small jumpers in the middle of the rails. Without these middle

    jumpers, only the bottom left rails (next to the 5V supply) actually have 5V and GND. Since the

    LED is connected to the upper left power and ground rails, the LED never got power! Therefore,

    you will probably need to use very short jumper wires (and some long ones on the end) to connectall the '+' rails (5V) together and all the '-' rails (GND) together.

    Some additional nit-picky notes about breadboarding:

    1. You won't listen to this rule. Neither did I initially. Use a few different colors of wire! It's

    really helpful to see where the power and gnd wires go if GND is black and 5V is red. I

  • 7/30/2019 Electronics Training Course 1

    19/32

    wired 200 connections using only orange. When things didn't work, it was hardto figure

    out where all the connections went.

    2. Don't worry about super-tight wires, and don't use huge loops. When cutting and

    stripping wire for breadboard connections, don't spend exorbitant amounts of time

    making the wire perfectly flat. It doesn't matter. That said, don't use 9" of wire when 1"

    will do. Make it clean.

    3. The 'making things clean' rule applies to LEDs, resistors, and crystals as well. Clip the

    legs! If you've got OCD like I do, it can be hard to permanently alter a part in this way.

    What if I need the legs to reach further away on a future project?! It's ok. Resistors cost

    $0.005 each. If in the future, you need a resistor with full legs to reach from point A to

    point B, just get a new one. It's not worth having lots of exposed legs that could bend and

    short to other exposed legs.

    Now with your power supply built up, turn your multimeter to voltage and check your board

    voltage by probing from the Blue rail (0V or GND) and the red rail (5V or VCC).

    Note: To use a multimeter you need to use both probes. Voltage refers to a potential. Using only

    one probe will get you nothing because you have to compare something against something else. In

    our world, we assume ground is 0V. So touch your black probe to any ground connection. Now

    you can measure the voltage on any other pin with the red probe. In the picture below, the black

    probe is touching the ground rail (0V), and the red probe is touching the 5V rail - thus we are

    viewing what voltage is exposed on the red probe compared to ground. If we put both probes on

    the 5V rail, the multimeter would show 0V because there is no difference in voltage between the

    probes.

    Guess what happens when you push the black probe against the 5V rail and the red probe againstthe ground rail? The multimeter will show -5V. This is because the multimeter assumes the black

    probe is touching 0V. There is still a difference of 5V between the probes so the multimeter shows

    -5V.

  • 7/30/2019 Electronics Training Course 1

    20/32

    4.98V on the 5V rail

    So you don't have 5.000V. Nothing in engineering is perfect. If you're within 100mV you're doing

    just fine. These cheap-o voltage regulators are cheap for a reason - and we don't need high-

    precision. 4.9V to 5.1V is just fine.

    Congratulations! You've built up your very first breadboard! Now leave this 5V power supply

    wired in your breadboard! You are going to use it many times...

    http://www.sparkfun.com/commerce/product_info.php?products_id=8357http://www.sparkfun.com/commerce/product_info.php?products_id=8357
  • 7/30/2019 Electronics Training Course 1

    21/32

    A 500mA PTC

    Quick Note:PTCsare your friend! PTC = positive temperature coefficient. Beginners will often

    create shorts or accidentally hook things up backwards. A PTC (also known as athermistor) is a

    device that will increase in resistance as current flows through it. These PTCs can be designed so

    that at a certain current flow (let's say 500mA), the resistance increases dramatically, thus

    limiting the current flow. Basically, the PTC acts as a resettable fuse! You will want to place this

    device in series, before your voltage regulator. If your circuit draws more than 500mA (if you

    short power to ground for instance), the PTC will heat up and limit the current to 250mA. Once

    you remove the short, the current will drop back down, the PTC will cool off and the circuit will

    start operating normally again. Very cool little component that has saved many of my designs

    from smoking.

    This is how the PTC looks in circuit. The PTC is wired in line. As the current of the circuit flows

    through the PTC, it will trip if the current is too large, cutting off the rest of the system.

    We love feedback! Please report typos, comments, or recommendations [email protected].

    Lecture 1 - Background and Power Supply

    Lecture 2 - How to Get Code Onto a Microcontroller

    Lecture 3 - What is an oscillator?

    Lecture 4 - UART and Serial Communication

    Lecture 5 - AVR GCC Compiling

    Lecture 6 - Soldering Basics

    Lecture 7 - SMD Soldering

    Lecture 8 - Eagle: Schematics

    Lecture 9 - Eagle: PCB Layout

    Lecture 10 - Eagle: Creating a new part

    Common Mistakes, Tips and Tricks

    http://www.sparkfun.com/commerce/product_info.php?products_id=8357http://www.sparkfun.com/commerce/product_info.php?products_id=8357http://www.sparkfun.com/commerce/product_info.php?products_id=8357http://en.wikipedia.org/wiki/Thermistorhttp://en.wikipedia.org/wiki/Thermistorhttp://en.wikipedia.org/wiki/Thermistormailto:[email protected]:[email protected]:[email protected]://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=93http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=104http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=106http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=108http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=110http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/tutorial/BeginningEmbedded/1-PowerSupply/PowerSupply7-L.jpghttp://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=111http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=110http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=110http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=109http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=108http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=108http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=107http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=106http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=106http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=105http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=104http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=104http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=95http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=93http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=93http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57http://www.sparkfun.com/commerce/tutorial_info.php?tutorials_id=57mailto:[email protected]://en.wikipedia.org/wiki/Thermistorhttp://www.sparkfun.com/commerce/product_info.php?products_id=8357
  • 7/30/2019 Electronics Training Course 1

    22/32

    Comments88 comments

    Loginorregisterto post comments.

    xxxlepexxx| about 5 years ago 3Thanks a lot, this tutorial is great, it has everything an electronic should know, even the obvious

    but tricky things. I saved it completely.

    wuziq| about 5 years ago 3really nice tutorial, i actually read the whole thing, and i never knew i could get so excited about aregulated power supply.. :D

    tr0nk| about 4 years ago 3if you just need to get some pretty lights blinking (for an art project or something), and you findthese tutorials overwhelming (even though theyre awesome (!!)), you may want to start withan arduino programmer instead:Arduino USB Boardhttp://www.sparkfun.com/commerce/product_info.php?products_id=666 http://www.arduino.cc/it is still recommended that you read through the tutorials (^_^)/

    tj| about 5 years ago 2That was really nice tutorial. I have a bachelors in engineering and have not used electroniccircuits in a while, so it really helped refresh a lot of things. Thanks for doing that.

    Penguinator| about 5 years ago 2Thanks for writing that article, Ive learned more from reading this than I have in a long time! Verywell written and easy to understand, which is different from many other books and articles Ivetried to read on electronics.

    nedium| about 4 years ago 2Thanks for very very helpful, easy to understand tutorial.But, i have a question. How should we use PTC?Serial connection as a resistor or like a cap?It would be very good if you can integrate PTC to schematic.

    o Nate| about 4 years ago 1Good questionit is wired in line. Ive added an updated schematic upon your request.Checkout the end of this page near the PTC image.

    Bogatyr| about 4 years ago 2Thanks for a great tutorial. Ive been wondering about these little switches used in breadboardpower circuits theyre all pretty wimpy in the current department, e.g., the one listed in the

    parts kit for this tutorial is rated at 200mA. Doesnt that mean that the entire current usage of thedesign hooked up to the supply circuit is limited to 200mA before the switch will weld open orotherwise destruct?All the beefier switches (1A+) that Ive seen are huge and dont have pins suitable fordirect/convenient use on a breadboard. Are there higher rated but BB-friendly (no solderingrequired) switches available? (Where?)thanks!

    o Larius| about 2 years ago 1

    https://www.sparkfun.com/account/loginhttps://www.sparkfun.com/account/loginhttps://www.sparkfun.com/account/makehttps://www.sparkfun.com/account/makehttps://www.sparkfun.com/account/makehttp://www.sparkfun.com/users/46694http://www.sparkfun.com/users/46694https://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd351000173http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/51869http://www.sparkfun.com/users/51869https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000341http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/29984http://www.sparkfun.com/users/29984https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000bafhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/commerce/product_info.php?products_id=666http://www.sparkfun.com/commerce/product_info.php?products_id=666http://www.arduino.cc/http://www.arduino.cc/http://www.sparkfun.com/users/47384http://www.sparkfun.com/users/47384https://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd3510001a4http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/52367http://www.sparkfun.com/users/52367https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000374http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/44764http://www.sparkfun.com/users/44764https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510003e2http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/7185http://www.sparkfun.com/users/7185https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000467http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/70815http://www.sparkfun.com/users/70815https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000d85http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/54461http://www.sparkfun.com/users/54461https://www.sparkfun.com/tutorials/57#comment-4eaad84a757b7fd351005760http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttps://www.sparkfun.com/tutorials/57/comments.xmlhttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad84a757b7fd351005760http://www.sparkfun.com/users/54461http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000d85http://www.sparkfun.com/users/70815http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000467http://www.sparkfun.com/users/7185http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510003e2http://www.sparkfun.com/users/44764http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000374http://www.sparkfun.com/users/52367http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd3510001a4http://www.sparkfun.com/users/47384http://www.arduino.cc/http://www.sparkfun.com/commerce/product_info.php?products_id=666http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000bafhttp://www.sparkfun.com/users/29984http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000341http://www.sparkfun.com/users/51869http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd351000173http://www.sparkfun.com/users/46694https://www.sparkfun.com/account/makehttps://www.sparkfun.com/account/login
  • 7/30/2019 Electronics Training Course 1

    23/32

    Id suggest semiconductor switching using a transistor rated for adequate current. Use thewimpy switch to turn on the base or gate of your transistor, and the transistor handles allcurrent.

    ncsuece| about 4 years ago 2Great tutorials! I really like to print out tutorials and follow along, esp. when they are long like this.

    Is there a better way to print these tutorials? The light gray text and gray columns on the sidemake it a real pain to print and read. Is there a PDF or print-formatted version available?Thanks and keep up the great tutorials!

    Manuel| about 4 years ago 2Well, this kind of 5V source isnt the type Id use. It wastes almost 50% of the power. This meansthat your 9V battery will last almost the half it should with a well made 5v source. There are someICsfrom maxim that achieve high efficiencies. Ive learned that in battery powered projects oneshould be as efficient as possible. Anyway, I think its a well made tutorial and its a good startingsource for ones first projects. By the way, you are so right about the PTCs. Ive seen several ofmy most sensitive ICs smoke to death in an instant and not because of short circuits. Whenusing batteries one has to take into account the short circuit current it gives. It may be too small(CR2032 for example) ortoo high and may give trouble because theres no limit. PTCs are life

    savers.

    SIGTERMer| about 4 years ago 2best tutorial so far. two downsides though:gray isnt the best color for this kind of reading.a printable version should be made availabe, if it hasnt been already. never the less, good job :)

    Andros1200| about 3 years ago 2You have a spelling error in your OR microcontroller code.if (A == 1 || B == 1){

    C = 1;}else{C = 0;{If you would notice the very last bracket is an opening bracket not a closing bracket.Very nice tutorial!

    Estwald| about 5 years ago 1Great tutorial, a nice addition for the totally inexperienced would be to add the diagrams for centerpositive and center negative barrel connectors.

    Gillerire| about 4 years ago 1I agree with the comment above; could you please add some more explanation of the PTC andhow it connects to the circuit.Also, I have always wondered about the values of filtering capacitors. Why do you use 100uF onone side and 10uF on the other? When should a 0.1uF be used?The explanation of the capacitor max voltage was very helpful. Something I never knew about.

    o Nate| about 4 years ago 1

    http://www.sparkfun.com/users/71950http://www.sparkfun.com/users/71950https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000e17http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/72551http://www.sparkfun.com/users/72551https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000eachttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/82374http://www.sparkfun.com/users/82374https://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd351001462http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/64429http://www.sparkfun.com/users/64429https://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001bcchttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/47195http://www.sparkfun.com/users/47195https://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd351000194http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/54387http://www.sparkfun.com/users/54387https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100045fhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/7185http://www.sparkfun.com/users/7185https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000468http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000468http://www.sparkfun.com/users/7185http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100045fhttp://www.sparkfun.com/users/54387http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83d757b7fd351000194http://www.sparkfun.com/users/47195http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001bcchttp://www.sparkfun.com/users/64429http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd351001462http://www.sparkfun.com/users/82374http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000eachttp://www.sparkfun.com/users/72551http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351000e17http://www.sparkfun.com/users/71950
  • 7/30/2019 Electronics Training Course 1

    24/32

    Good points. Ive added more on the PTC and caps. Larger caps obviously store more energy,but they react more slowly. If you have a large power outage (power dips for 10-100ms), a bigcap (100uF to 1000uF) will help hold up the falling voltage. A smaller cap (0.1uF) will helpsuppress higher frequency noise and shorter power dips (noise in the 1us to 100us range).Therefore, 0.1uF caps are located near the microcontroller to help with short bursts, where100uF and 10uF caps are used on the power rails.

    Gillerire| about 4 years ago 1Thanks Nate :)

    peterb| about 4 years ago 1this is a great tutorial, having fun.when i set up my power supply though, im only gettin g 4V on the rails. why would that be?thanks,Peter

    o ico| about 3 years ago 2The LM7805 ouput is 4.3V when using a 5V power supply, but 5.01V when using a 9V or 18V

    power supply.Checked the datasheet of LM7805, which said it should works well on input Vo = 5V to 18V and24V, not sure why it ouput 4.3V when the input is 5V only.

    boris_1981| about 3 years ago 1oopss. gave it the wrong smilye.

    cpjolicoeur| about 4 years ago 1Im still relatively new to electronics and have a question. When talking about the LED youmentioned:You may be wondering if the resistor/LED order matters. It does not. The resistor can come firstand then the LED or as shown. Either configuration will correctly limit current through the LED."Why is this so? I dont understand why you can put the resistor on either side of the LED.

    Wouldnt the resister need to come before the LED to resist the flow of power into the LED? Howdoes it help afterwards when the power has already gone through the LED?

    TBaumg| about 4 years ago 1cpjolicoeur,An LED and Resistor in series create a single path(circuit) for electricity to flow through. Itdoesn?t matter if the resistor is before or after the LED because the total impedance of that circuitis limited by the resistor.It is similar to a water hose and a valve. The valve is like a resistor; it can limit how much watercan flow through it. It doesn?t matter if the valve is at the supply side or the open side of thehose, the end result will be the same limited amount of water.As long as you limit the amount of current that flows through the LED it will be fine. Hope thishelps.

    TheDoc| about 4 years ago 1Excellent tutorial. One thing Id like to ask is that my Voltage Regulator gets fairly warm not sowarm as to burn me. Nevertheless, Im working on a gadget (mostly just an RGB thingy) that Iwant to give my grandma. Anyway, I just want to figure out to keep the voltage regular fromgetting so hot. Can I just put an extra resistor between the power in and the regulator orsomething?Wicked tutorial at any rate. Thanks tons!

    http://www.sparkfun.com/users/54387http://www.sparkfun.com/users/54387https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510004e1http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/52971http://www.sparkfun.com/users/52971https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000589http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/138675http://www.sparkfun.com/users/138675https://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd3510041c1http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/72126http://www.sparkfun.com/users/72126https://www.sparkfun.com/tutorials/57#comment-4eaad848757b7fd351004af3http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/56506http://www.sparkfun.com/users/56506https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100058bhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/121http://www.sparkfun.com/users/121https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100058fhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/49023http://www.sparkfun.com/users/49023https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510005f3http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510005f3http://www.sparkfun.com/users/49023http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100058fhttp://www.sparkfun.com/users/121http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100058bhttp://www.sparkfun.com/users/56506http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad848757b7fd351004af3http://www.sparkfun.com/users/72126http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd3510041c1http://www.sparkfun.com/users/138675http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000589http://www.sparkfun.com/users/52971http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510004e1http://www.sparkfun.com/users/54387
  • 7/30/2019 Electronics Training Course 1

    25/32

    BeanForge| about 4 years ago 15.1V and a lovely yellow light!! Thanks for a great, well thought out tutorial. On tomicrocontrollers

    MattTheGeek| about 4 years ago 1

    Thanks for the tutorial Nate.

    David McFarland| about 4 years ago 1Great tutorial. Thanks.A couple of questions about the capacitors:1. why do you use two?2. what would happen if you switch their positions (put the 10uF where the 100uF is in yourschematic, and vice versa).

    o Chandhooguy| about 5 months ago 11. The voltage regulators have fluctuations too; after the electricity goes through them,

    there may be new fluctuations.

    2. Well, your10uF doesnt like the 9V, and your 100uF doesnt like the 5V. If you do that,most likely you will damage(ever so slightly) your caps.

    Michelle| about 4 years ago 1a bit lengthy but awesome tutorial

    mouse-wiz| about 4 years ago 1Im not sure Ive ever been so excited to see an LED light up. Great write up =D

    spangaroo| about 4 years ago 1Great tutorial. I love learning more about power flows.I can see the resistor in the photo, but I dont see the 1N4001 diode. Am I missing something? Im

    just trying to study all the components so I can set it up properly from the beginning.

    o Snibble| about 3 years ago 1See Nates comment in the section below the first photo of the breadboard:I did not install a reverse protection diode. Ionlyuse center positive power supplies so I knowIm safe."(sounds like famous last words to me)

    KB8RWX| about 4 years ago 1Outstanding tutorial! Thanks.

    NathanWong| about 4 years ago 1

    Thanks for taking the time to post such a great tutorial. I apologize if this is taken into account insome of your later tutorials (I intend to read them all!), but I just have one question: Somecomponents, like the little LCD screens sold here, require 3.3V. How would this usually beprovided? Would it be a parallel split at the end of the power circuit and another voltage regulator,or would it be a split before the voltage regulator and then have two circuits, one at 5V and one at3.3V? Im just trying to understand how to take advantage of having 9V (albeit unregulated) andneeding both 5V and 3.3V. :) Thanks again!

    thejam| about 4 years ago 1

    http://www.sparkfun.com/users/57931http://www.sparkfun.com/users/57931https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100061bhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/55643http://www.sparkfun.com/users/55643https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510006a9http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/54968http://www.sparkfun.com/users/54968https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100080ehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/339315http://www.sparkfun.com/users/339315https://www.sparkfun.com/tutorials/57#comment-50db6ef2ce395fca76000000http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/63683http://www.sparkfun.com/users/63683https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000997http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/62773http://www.sparkfun.com/users/62773https://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100099ahttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/75912http://www.sparkfun.com/users/75912https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351001091http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/126644http://www.sparkfun.com/users/126644https://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd351003d99http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/77598http://www.sparkfun.com/users/77598https://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd35100118ahttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/83846http://www.sparkfun.com/users/83846https://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd35100153chttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/84283http://www.sparkfun.com/users/84283https://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd3510015e0http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd3510015e0http://www.sparkfun.com/users/84283http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd35100153chttp://www.sparkfun.com/users/83846http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd35100118ahttp://www.sparkfun.com/users/77598http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd351003d99http://www.sparkfun.com/users/126644http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83f757b7fd351001091http://www.sparkfun.com/users/75912http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100099ahttp://www.sparkfun.com/users/62773http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd351000997http://www.sparkfun.com/users/63683http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-50db6ef2ce395fca76000000http://www.sparkfun.com/users/339315http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100080ehttp://www.sparkfun.com/users/54968http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd3510006a9http://www.sparkfun.com/users/55643http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad83e757b7fd35100061bhttp://www.sparkfun.com/users/57931
  • 7/30/2019 Electronics Training Course 1

    26/32

    I just got the parts in the mail yesterday Whats funny to me is that I thought all the componentswere much bigger than they actually are. Probably because Ive only been looking at pictures forthe past 2 weeks.But I put the power supply together, and it worked! The LED lit up and didnt burn out. And evenmore than that, I can read the schematics now too! It all makes sense now that I can see it in myhands and on the schematic.Thanks for these tutorials!

    Surya Sharma| about 4 years ago 1How are PTCs coded? I need one for 500mA / 5V (USB specifications) The ones I have ReadC1122 and 0135. How many amps are these?

    blalor| about 3 years ago 1Theres a broken image; the image above the text The cap has a minus sign on the coverindicating that pin needs to go to GND. points tohttp://www.sparkfun.com/commerce/images/Caps -3.jpg, which is 404'ing.

    hm| about 3 years ago 1

    This is a great tutorial! It was a lot of fun to read it cause there is nothing like this for computerprogrammers that know nothing of electronics!One point to mention is to Note that I BURNT MY LED because the GND pin of my voltageregulator was not connected to the shared ground! The regulators output pin instead of +5V wasgiving out +9.8 V ! Just because of a missing GND connection.I suggest we make the GND connection of our regulator the final gate for all grounds connectionsin this circuit, so if that goes cut, our circuit would turn off instead of have dangerous voltage !

    Techn010g1ka11| about 3 years ago 1Great tutorial. Thanks!

    Ngesh| about 3 years ago 1The tuitorial is very informative. It has turned me into a Sparkfun fan!

    warlord| about 3 years ago 1I keep being amazed at how helpful the sparkfun community is. Good job! Well explained!

    Robban| about 3 years ago 1Would love to hear some examples of where you feel PICs are inadequate for your purposes. Is itjust very specialized tasks or just in general? Im still just a newbie but Ive played around with afew different PICs in several projects and Ive yet to come across something they cant do (ofcourse, these are basicprojects).

    ebrandt| about 3 years ago 1This worked for me according to the instructions and I used ubuntu as the (parallel port) PCprogrammer. I had to make two small edits to the makefile to get it to work:1. remove the -P lpt1 from the AVRDUDE_FLAGS (its not called lpt1 on ubuntu, and the defaultvalue is fine, so its OK to ommit that flag entirely.)2. I had to add -E noreset to the AVRDUDE_FLAGS. This deactivates the /reset line on theparallel port after programming. Without it, pin 1 stayed low after programming until Idisconnected the programmers reset line. With this flag I can leave the programmer connected.Just a few tips that anyone else using ubuntu might find useful. Happy blinking

    SeaJay| about 3 years ago 1

    http://www.sparkfun.com/users/84326http://www.sparkfun.com/users/84326https://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd35100167ehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/32415http://www.sparkfun.com/users/32415https://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001a49http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/90322http://www.sparkfun.com/users/90322https://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001a54http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/94679http://www.sparkfun.com/users/94679https://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001cefhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/96706http://www.sparkfun.com/users/96706https://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001ddchttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/81021http://www.sparkfun.com/users/81021https://www.sparkfun.com/tutorials/57#comment-4eaad842757b7fd351002023http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/36996http://www.sparkfun.com/users/36996https://www.sparkfun.com/tutorials/57#comment-4eaad842757b7fd3510020d5http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/115677http://www.sparkfun.com/users/115677https://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd3510025cehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/118736http://www.sparkfun.com/users/118736https://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd35100295dhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd35100295dhttp://www.sparkfun.com/users/118736http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd3510025cehttp://www.sparkfun.com/users/115677http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad842757b7fd3510020d5http://www.sparkfun.com/users/36996http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad842757b7fd351002023http://www.sparkfun.com/users/81021http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001ddchttp://www.sparkfun.com/users/96706http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001cefhttp://www.sparkfun.com/users/94679http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001a54http://www.sparkfun.com/users/90322http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad841757b7fd351001a49http://www.sparkfun.com/users/32415http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad840757b7fd35100167ehttp://www.sparkfun.com/users/84326
  • 7/30/2019 Electronics Training Course 1

    27/32

    Can the Pocket AVR Programmer be used instead of the AVR STK Parallel Port DongleProgrammer to support laptops without parallel ports? If not, are there any other fixes? Thanks inadvance.

    alexl| about 3 years ago 1I get a consistent 6.5ish volts out of the 10 or so L7805CVs Ive tested this with.

    Whats going wrong here? Im using a standard 9v battery as my power source.

    o alexl| about 3 years ago 1I figured it out: the batteries were dead in my multimeter.

    blen2r| about 3 years ago 1Nice tutorial!I was wondering if that ripple we were filtering with the capacitors is present when the power iscoming from a battery?

    Klone38| about 3 years ago 1ARM microcontrolles actually stand for Advanced RISC Machines which were made by ARM

    holdings in the mid 1980 as a original substitute for the Motorola 68000 and NationalSemiconductor 32016 to be used in the Acorn Business Computer. the Motorola 68000 andNational Semiconductor 32016 wernt strong enough in the computer so ARM holdings decided toinvent a new chip called the ARM. for more info you can wikipedia ARM architecture, ARMHoldings, or Acorn Computers.

    ThomasCruz| about 3 years ago 1Hi, i would like to know if I can use an alternative part instead of using PTC because PTC is notavailable here but NTC is.. can anyone help me about this thanks in advance

    Snibble| about 3 years ago 1Agree that the AVR stuff is fun to play with at the price point, but have recently been doing

    MSP430 stuff at work and ran across a deal that might be interesting for some readers. $4.30 fora couple of value line MSP chips and supporting board for experimenting.http://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2

    RoboKaren| about 3 years ago 1I hope you know that the technical name for an LED that has had too much forward or reversecurrent through it is a DED: Dark Emitting Diode.Please modify your tutorial accordingly. :)

    o Single T| about 3 years ago 1Thanks for the information, and input. We will make some changes.

    CTC-001| about 3 years ago 1This is a great lecture and it gets all this cool raw electronics gear in your hands. Pretty new toelectronics so this is perfect. This simple circuit put together with an LED and everything, takenalong with the first 50 pages or so of Electrical Engineering 101, has really helped me to feel like Igot my feet wet. Fun!http://www.sparkfun.com/commerce/product_info.php?products_id=9458

    FLITE| about 3 years ago 1

    http://www.sparkfun.com/users/122316http://www.sparkfun.com/users/122316https://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd351002ab9http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/122316http://www.sparkfun.com/users/122316https://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd351002abahttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/89739http://www.sparkfun.com/users/89739https://www.sparkfun.com/tutorials/57#comment-4eaad844757b7fd351002f29http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/129043http://www.sparkfun.com/users/129043https://www.sparkfun.com/tutorials/57#comment-4eaad844757b7fd35100323ahttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/139775http://www.sparkfun.com/users/139775https://www.sparkfun.com/tutorials/57#comment-4eaad845757b7fd351003a43http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/126644http://www.sparkfun.com/users/126644https://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd351003d93http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2http://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2http://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2http://www.sparkfun.com/users/79270http://www.sparkfun.com/users/79270https://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd3510040fehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/49769http://www.sparkfun.com/users/49769https://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd35100411bhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/138189http://www.sparkfun.com/users/138189https://www.sparkfun.com/tutorials/57#comment-4eaad847757b7fd35100471bhttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/commerce/product_info.php?products_id=9458http://www.sparkfun.com/commerce/product_info.php?products_id=9458http://www.sparkfun.com/users/160361http://www.sparkfun.com/users/160361https://www.sparkfun.com/tutorials/57#comment-4eaad849757b7fd351004f71http://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad849757b7fd351004f71http://www.sparkfun.com/users/160361http://www.sparkfun.com/commerce/product_info.php?products_id=9458http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad847757b7fd35100471bhttp://www.sparkfun.com/users/138189http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd35100411bhttp://www.sparkfun.com/users/49769http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd3510040fehttp://www.sparkfun.com/users/79270http://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2http://www.ti-estore.com/Merchant2/merchant.mvc?Screen=PROD&Product_Code=MSP-EXP430G2http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad846757b7fd351003d93http://www.sparkfun.com/users/126644http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad845757b7fd351003a43http://www.sparkfun.com/users/139775http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad844757b7fd35100323ahttp://www.sparkfun.com/users/129043http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad844757b7fd351002f29http://www.sparkfun.com/users/89739http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd351002abahttp://www.sparkfun.com/users/122316http://www.sparkfun.com/static/comment_helphttps://www.sparkfun.com/tutorials/57#comment-4eaad843757b7fd351002ab9http://www.sparkfun.com/users/122316
  • 7/30/2019 Electronics Training Course 1

    28/32

    I dont totally understand this part:In the old days, microcontrollers were OTP or one-time-programmable meaning you could onlyprogram the micro once, test the code, and if your code didnt work, you threw it out and triedagain. Now micros are flash based meaning they have flash memory built inside that allows theircode to be written and rewritten thousands of times. Ive been programming micros for years andalways burn out the microcontroller far before I hit the limit of flash programming cycles.I get that it means you can program them more than once now, but I am unsure as to what ismeant by programming

    ibot| about 3 years ago 1Excellent tutorial! I had never thought about using a PTC in a voltage supply before, its perfect soa beginner like me wont burn up any components.

    dantheman| about 2 years ago 1Thanks I know absolutely nothing about electronics and was able to build the bread board in justthree evenings.I even used and lit up the extra LED Wow

    The thing I dont really understand about bread boards is how the hole/rows are configured. If you

    are in row 5, for instance is the row 6 always meant to be the ground row? Or is each row isolatedfrom the other?

    Also I start with AC current in the house but the when you go into the bread board now there is aground. Is this still AC current now or does it turn into DC. Thanks in advance I love this site.

    !LH@N| about 2 years ago 1Hi!Great Tutorial, thanks a lot! I just have a quick question. Why do you put the caps parallel? Howdoes that work? I always thought if you put something parallel you have the same voltage, butobviously there is 9V on one cap and 5V on the other. How does that work?Please explain

    o !LH@N| about 2 years ago 1Never mind, found the answer myselfthe 10 uF cap is in series with the regulator, and themtwo are parallel to the other cap. Thanks anyway!

    Rohar| about 3 days ago 1Not quite true. Both caps are installed parallel to the vreg. They have to be, as they block DCcurrent once they are fully charged. If your oscilloscope shows output power of 5v for a fewseconds, then drops to 0v, you may have installed a capacitor in series.

    Member #207315| about 2 years ago 1Why dont the pictures work forthis tutorial?

    o dpgol88| about 2 years ago 1I am having the same problem.Also,there is some Permission Denied error, when I try to viewthe images separately.

    lscarmic| about 2 years ago 1Me too. Sup with that?

    http://www.sparkfun.com/users/96485http://www.sparkfun.com/users/96485https://www.sparkfun.com/tutorials/57#comment-4eaad849757b7fd3510050echttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/161512http://www.sparkfun.com/users/161512https://www.sparkfun.com/tutorials/57#comment-4eaad849757b7fd3510051dehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/200393http://www.sparkfun.com/users/200393https://www.sparkfun.com/tutorials/57#comment-4eaad84d757b7fd35100703ehttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/static/comment_helphttp://www.sparkfun.com/users/200393http://www.sparkfun.com/users/200393https://www.sparkfun.com/tutorials/57#comment-4eaad84d757b7fd35100