Current Confusion

I have a confusion on the current flowing through the circuit.

Recently, I am searching for suitable power supply to supply my arduino board and come accross a website (I forgot what website) that for any plug that I wanna buy for an equipemnt, it must have the same Voltage.

It also says that the current rating can be anything as long as it it above the required current. Since the equipment will take right amount of current that it only required and the current rating stated on the plug is just the maximum amount of current it can provide which I must not exceed.

My question is, if an equipment only absorb the required amount of current, why in the first place do we need resistor?I mean, when I came accross LED tutorial, we need to put 330 ohm resistor to limit the current since arduino provides 250mA.

Isn't it that the LED will only take the current that it requires? and 250mA is just the maximum combination if currents required by my equipment connected to the same Pin?

What you said is correct for most cases, but LEDs are among the few components that will take any current they can.

Have a look at the right hand side of this chart: once there's enough forward voltage, the graph is pretty much vertical.

led volt current.png

A single IO pin should be limited to 20mA, which as it turns out is generally the upper limit for an LED also to prevent it overheating and failing.
(Vs - Vf)/resistor = current
where Vs is the Arduino source (5V), Vf is the forward voltage of the LED when turned (around 2.2V for Red for example), resistor is the current limit resistance in ohms, and current is the resulting current.

With the numbers above: (5V - 2.2V)/330 ohm = ~8.5mA.
Say you wanted more current flow - swap resistor and current and solve for resistor instead:
(5V - 2.2V)/.02A (i.e. 20mA) = 140 ohm. 150 is a standard resistor value, I'd use that.

At 20mA, the Arduino output is guaranteed to be at least 4.2V, and will rise towards 5V with less current. Above 20mA, the voltage will drop as the output transistor is asked to provide more current; Rds of the output transistor causes more voltage to develop across the transistor (V = current x resistance) and less voltage is available for the LED.

I don't know where you got 250ma from. In a DIP, the '328P has one VCC pin, it is rated for 200mA Absolute Max. More than that and you increase the risk of the part failing.

My question is, if an equipment only absorb the required amount of current, why in the first place do we need resistor?

You are mixing up equipment with component.

Equipment is a collection of components designed to work at a specific voltage. When given that voltage it will take the current it was designed for.

A component on the other hand needs to be designed into a system so that it takes the current it is designed to take. Therefore there might be a need to limit that current in some way.

How about motors?If i have motor that can accept up to 2.0A. Can I use power supply which has rating of 2.5A?

Akh_f:
How about motors?If i have motor that can accept up to 2.0A. Can I use power supply which has rating of 2.5A?

Yep since the winding has a resistance and a motor follows Ohms Law. Long as you keep below the max voltage allowed....

Think about a light bulb in your house. They are 240V ( or 120V in the US ). However a 40W bulb will draw less current than a 100W bulb. All will be well.
However if you take a 3V flash light bulb and connect it to the mains it will draw too much current and BANG!

In the case of a motor, you also need to know the stall current. This is how much current it will draw when power is first applied, before it starts spinning. Your power supply must be able to supply this.

If you are going to use electronics, you should learn basic electronics. Buy a book or read some tutorials online or some youtube videos.