LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Having trouble with power and power factor form EPM_Power.VI

Hello, 

 

I am trying to build a very simple VI using LabVIEW and a PXIe-1062Q Chasis with two NI PXI-4071 DMM Cards.  My goal is to:

 

A. Measure AC Current and Voltage

B. Calculate Real Power (Watts) and Power Factor

 

So far, I can measure Voltage just fine using DMM Waveform measuring.  I am having trouble reading current as a waveform.  When I do, It is being seen as an AC signal jumping from 0.689 to -0.689 and the waveform read is reading all points in between.  This is causing my power factor and power to be incorrect (Using EPM_Power.VI form EPM Pallete). 

 

I tried to use the RMS function to get a better current reading and then generate a waveform, but this pretty much does the same thing.  I also tried to just read current as a digits measurement, but that makes my power factor 1 and my power is incorrect because of this.

 

I know what values I am supposed to get because I have a Magtrol 6510e Power Analyzer wired in to verify measurements.

 

I should be getting:

 

Input Voltage: 237.89

Input Current: 0.678

Power:           164 W

Power Factor 0.95

 

With LabView, I get:

 

Input Voltage: 237.89

Input Current: anywhere from 0.678 to -0.678 or 0.678 if I just do digits measurement but power factor becomes 1

Power:           Depends on the current reading but is inaccurate

Power Factor all over the place.

 

Please Help Me.  I have attached two VIs to this post.  The first one is using the DMM Measure Digits and the Second uses DMM Measure Waveform.

 

Thank you.

 

Scott

0 Kudos
Message 1 of 17
(4,935 Views)

What values do you get using the DMM Soft Front Panel, at least for Voltage and amps?

Applications Engineering Specialist - Semiconductor Test
National Instruments
0 Kudos
Message 2 of 17
(4,919 Views)

I don't know what you mean by soft DMM.  Unless you mean the DMM in measurement and automation DMM.  WHen I use that, I get the right current value.  Also if I use RMS, I get the right value, but if I create a waveform from the RMS value, then Power factor becomes 1 and doesn't change.  If I look at my input cureent waveform, it goes from -0.698 to 0.698 and I believe that Labview is sampling from points all over this waveform and that is creating the several values in between.  I've tried to tweek the number of samples and rate but, I just can't get it to give me even close to stable values.

0 Kudos
Message 3 of 17
(4,909 Views)
0 Kudos
Message 4 of 17
(4,898 Views)

The other thread was previously linked to this one. Please keep this thread as the active one.

Kareem W.
National Instruments
Web Product Manager
0 Kudos
Message 5 of 17
(4,883 Views)

That's fine by me. As long as we have one thread active, instead of three.

 

To OP: See the confusion that gets caused by multiple threads?

0 Kudos
Message 6 of 17
(4,868 Views)

Scott-

 

Have you looked at the examples found in Start>>Programs>>National Instruments>>NI-DMM>>Examples?  Try just running one of the shipping examples to see if you get the correct values.  If you do, then modify these to add the power function.

 

Thanks,

 

Sean

Applications Engineering Specialist - Semiconductor Test
National Instruments
0 Kudos
Message 7 of 17
(4,833 Views)

Yes,  None of them measure current and voltage like I am.  I am measuring in line current, not with a current clamp.  Im wondering if it may be my sample rate and number of samples. How do I calculate the adaquate waveform for the power VI?

0 Kudos
Message 8 of 17
(4,818 Views)

I'm not sure what you mean by "adequate waveform." The Power (3-phase)(AC only) subVI takes the rms of the AC current and AC voltage, does a conversion and then outputs the different powers, but it requires the voltage and current phasors as input.  When I downloaded this toolkit, this VI did not show in the palette, but I found it going to the user.lib folder.  Try this modified version of the VI you posted and let me know what you get.  I looked into the subVI that you have been using, and it should extract the correct information from a waveform.  It may have to do with whether or not your acquisition of both the voltage and current are in phase.  Also, how do you know what your values should be? 

Applications Engineering Specialist - Semiconductor Test
National Instruments
0 Kudos
Message 9 of 17
(4,791 Views)

I think I may have caught what my proble is but I don't know how to fix it.  I am now using a current transformer to get my current reading and then sending my current waveform into the phasor vi from the power pallette.  This is showing me the current phase angle.  The phase angle will jump from -230 degrees to - 166 degrees in a second.  It is random.  I think this is causeing the power function to not be able to compare the voltage and current to get power because the current phase is jumping so much. 

 

I am using the attached VI to measure input AC voltage and current to a ballast for an LED powered lamp.  We normally use a magtrol 6510e power analyzer to measure the power.  I havve this wired in too to let me know what my values should be. 

 

now that I know my problem, I don't know how to correct this phase angle problem. 

 

I have modified my VI and attached it to this post. I also took some screen shots of my VI running showing how the phase angle varies and my signals.

 

I did try to clean up the noise on the current signal, which labview did, but the phase was still the same.

 

Scott

0 Kudos
Message 10 of 17
(4,774 Views)