# Measure current by using Shunt resistor! Please advice me [ mikroC ]

Status
Not open for further replies.

#### boyguitar1

##### Member level 1
Hi Sir...

I want to measure current from my dc fan (4 dc fans 5V , Total current ~ 1.40 A.)
and send data to PC (VB2008)

So I would like to know about Value of Shunt resistor , watt?

This is my first project aboud current measurement.

#### andre_teprom

##### Super Moderator
Staff member
Sugestion :
I = 1,4A
R = 0,1R
P = (0,1R)*(1,4A)^2 = 0,19 ~1/5W
V = (0,1R)*(1,4A) = 0,14V

Use an OpAmp to multiply that voltage to full-range magnitude of A/D :

K = 5 / 0,14 ~ 35
K = 3,3 / 0,14 ~ 23

Hope this help

+++

---------- Post added at 10:45 ---------- Previous post was at 10:31 ----------

Another option without use of OpAmp.
But power dissipation at resistor increases too much :

5v = R * (1,4A) => R ~ 3,5 --> using Vref A/D to 5v
3,3v = R * (1,4A) => R ~ 2,3 --> using Vref A/D to 3,3v

The wattage :

P = 5v * (1,4A) ~ 7w
P = 3,3v * (1,4A) ~ 4,6w

+++

You simply measure the voltage drop across a resistor in series with the load - simple ohms law, a 1 ohm resistor will drop 1V for every amp of current.

As you probably can't afford to lose 5V off your supply rail, it's usual to use a smaller resistor and amplify the voltage drop with an opamp - this also allows you to reference the voltage to 0V (by using a differential opamp circuit.

#### boyguitar1

##### Member level 1
Thank you Som much for all.
but
Can anybody give me some example code on mikroC ? Thank you !!

varunme

### varunme

Points: 2
Status
Not open for further replies.

Replies
12
Views
8K
Replies
11
Views
1K
Replies
5
Views
2K
Replies
4
Views
1K
Replies
4
Views
3K