Go Down

### Topic: Arduino Current Measuring Project (Read 2221 times)previous topic - next topic

#### fatopato

##### Jun 29, 2015, 05:33 pm
Hello, I am trying to measure current with Arduino by using non-invasive curent sensor:
https://www.sparkfun.com/products/11005

That sensor has 30A max current value. Therefore I calculated burden resistor as it is mentioned at:
http://openenergymonitor.org/emon/buildingblocks/ct-sensors-interface

And I found ideal Burden resistance as : 117,9. Then I used 2*56=112 Ohm Resistors to get approximate value.

Then I build that circuit and run the code (I changed 33 Ohm resistor with 2*56 Ohm):
http://openenergymonitor.org/emon/buildingblocks/how-to-build-an-arduino-energy-monitor-measuring-current-only

There are some results but even though I unplug the sensor it keeps measuring similar value. Also Irms value is about 200 all the time. Is that normal or what causes the error?
Thank you

#### fatopato

#1
##### Jul 01, 2015, 11:56 am
Is that because of calibratiom or the circuit?

#### TomGeorge

#2
##### Jul 01, 2015, 12:39 pm
Hi,
Can you post a picture of your project.
Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Can you please post a copy of your sketch, using code tags?
See section 7 http://forum.arduino.cc/index.php/topic,148850.0.html

Tom....
Everything runs on smoke, let the smoke out, it stops running....

#### fatopato

#3
##### Jul 01, 2015, 03:09 pm
This is the circuit:

This is what i have done:
http://i.imgur.com/NPKSihH.jpg?1

When i connect sensor to circuit, results around: 32 A
When i disconnect it, results around 9 A
when i disconnect A1 input pin, results around 3 A

Code: [Select]
`#include "EmonLib.h"                   // Include Emon LibraryEnergyMonitor emon1;                   // Create an instance void setup(){    Serial.begin(9600);   emon1.current(1, 17.9);             // Current: input pin, calibration.  //calibration is explained bellow} void loop(){  double Irms = emon1.calcIrms(1480);  // Calculate Irms only   Serial.print(Irms*230.0);         // Apparent power  Serial.print(" ");  Serial.println(Irms);          // Irms}`

#### DrDiettrich

#4
##### Jul 02, 2015, 05:07 am
Try to dump the raw A1 values. analogRead(A1) should be constant (~512) with the sensor removed.

#### TomGeorge

#5
##### Jul 02, 2015, 10:05 amLast Edit: Jul 02, 2015, 10:13 am by TomGeorge
Hi,
Find attached a schematic of  your project.
The circuit biases the current transformer so with no current V1 has half Vcc or 1/2 of 5Vdc= 2.5V.
When AC is conducted through the transformer, the output will be an AC signal on the 2.5Vdc.
The library converts this reading to RMS.
With the coil disconnected your should have 0 Arms.

Tom....
As you may gather I have an aversion to fritzy diagrams, they  are not schematics, and do not very clearly show how a circuit works.
(Sorry schematic shows A0 not A1)
I hope  you aren't trying to measure DC Current, this unit only measures AC current.
Everything runs on smoke, let the smoke out, it stops running....

#### dave-in-nj

#6
##### Jul 02, 2015, 12:54 pm
http://i.imgur.com/NPKSihH.jpg

you have lots of jumper wires to connect the different devices.

you have 10k highlighted but boxed over 2 resistors.
looks like they are supposed to be two to create a voltage dividor.    I assume that the note should be 2x10k

it also looks like the green jumper from the voltage divider is next to the yellow that connects to (or is supposed to connect to) the voltage divider.

I would re-visit that connection.

#### fatopato

#7
##### Jul 02, 2015, 03:57 pm
I just modified the circuit :

Then results:
-when sensor is not connected: around 0.3A
-when sensor is connected: around 1.4A
-when A1 pin is disconnected : around 3A

What could be the problem?

#### DrDiettrich

#8
##### Jul 02, 2015, 04:15 pm
The problem can reside in the library or in your circuit. Try debugging without the library first.

Go Up