Understanding basic

hello guys, i'm new in Arduino...i never used electronics, i bought Arduino starter kid and i have a question about the project 2.

At the beginning the book explains that the led gets passed thought by the electrical current in one single direction and if the tension is too high the led would burn, that's way we need a resistance.

In the first project, the resistance is placed before the led. It is used as bridge to pass the electricity from the positive line of the breadboard to the horizontal line that gives power to the first foot of the button.

In the second project, the resistance is placed after the led. It used as bridge between the "cathode" and the line of ground of the breadboard. This thing confused me....

if we are using a circuits of direct current, the current starts at 5V from Arduino and it passes the whole circuit. if meet first the resistance, the current is decreased to the maximum that the led support (23mA).
if the current start from Arduino at 5V, it passes the whole circuit and meet the led, doesn't the current arrive in a measures that burns the led?

Why in the second project the resistance is placed at the "exit"? why it's placed after? shouldn't the led burn? :astonished: :astonished: :astonished:

In a series circuit the current in all parts is the same. You have to consider the whole of the current path not just part of it.

Current dose not get "used up" in any one component, that is a basic misunderstanding about the nature of electricity.

the current starts at 5V from Arduino

No you do not consider the passage of current, you look at the current flowing as a whole.

if meet first the resistance, the current is decreased

As I said no, it is the current path as a whole, not a part of it.

so if the entering current is 5v it stays 5v in all the parts of the circuit... right?

so components as leds or others doesn't consume current, they just needs it to pass throught. but in this case my doubt is: if the current is always 5v, how does the resistance works? if it doesn't "block" some current, how does it work? and what's the purpose of it?

In series circuits (where parts are "in a line") the same current flows through all of the parts. So in this particular application, you can interchange the resistor & LED and it will work the same.

You can think of water in a pipe.* A valve turned partly-off is like a resistor... it "resists" or "restricts" current flow. It doesn't matter which end of the pipe you put the restriction on, the water-flow is the same.

If you take an electronics class, the 1st thing you learn is [u]Ohm's Law[/u], which describes (mathematically) the relationship between voltage, resistance, and current. Next, you'd learn [u]Kirchoff's Laws[/u], which describe how voltages and currents combine or divide in series and parallel circuits.

There is a LOT to electronics, and if you were taking electronics in college you wouldn't learn about microcontrollers unil about the 3rd year! ...So as a hobbyist teaching yourself, you'll be jumping-around and jumping-ahead to learn whatever you need to know for whatever you're building.

  • The "water in a pipe" analogy isn't perfect, especially since water flows freely out of an open pipe, but no current flows from an open-disconnected wire. :wink: But, sometimes it can be helpful to think of current as the amount of water flowing, and voltage as water pressure.

so if the entering current is 5v it stays 5v

Current is measured in amps not volts, your question does not make sense.

so components as leds or others doesn't consume current

All the components in the path have current flowing through them and as such consume it. Current however never vanishes it simply flows round the circuit. The resistance of the circuit as a whole defines the size of the current.

LEDs are a special sort of component. To a first approximation no matter how much current flows through it the voltage across it never changes. This is not what happens to components like resistors.

As to LEDs read this:-
http://www.thebox.myzen.co.uk/Tutorial/LEDs.html

so if the entering current is 5v it stays 5v in all the parts of the circuit... right?

so components as leds or others doesn't consume current, they just needs it to pass throught. but in this case my doubt is: if the current is always 5v, how does the resistance works? if it doesn't "block" some current, how does it work? and what's the purpose of it?

The voltage is divided among the series parts. Let's say there is 2V "across" the LED. That would mean there is 3V across the resistor.

If you wire like this: 5V -> resistor -> LED -> Ground

Your multimeter will measure 2V if you connect the - meter lead to ground, and the + meter lead to the junction of the resistor & LED.

If you wire like this: 5V -> LED -> resistor -> Ground

Your multimeter will now measure 3V if you connect the - meter lead to ground, and the + meter lead to the junction of the resistor & LED.