Go Down

### Topic: Calculating Power Factor Using ARDUINO UNO (Read 10522 times)previous topic - next topic

#### Javid

##### Jul 28, 2014, 01:18 pm
Hello,

I am new in ARDUINO field. Can somebody please help me with the code to find power factor ?

#### cmiyc

#1
##### Jul 28, 2014, 05:26 pm
That's a pretty common calculation.  Why are you looking for something specific to Arduino?
Capacitor Expert By Day, Enginerd by night.  ||  Personal Blog: www.baldengineer.com  || Electronics Tutorials for Beginners:  www.addohms.com

#### Peter_n

#2
##### Jul 28, 2014, 05:27 pm
Power factor ? What is that ?
Does it have to do with the mains ? Perhaps you can find information at the openenergymonitor site : http://openenergymonitor.org/emon/

#3
Quote

power factor ?

Of what?

#### blcodemonkey

#4
##### Aug 06, 2014, 03:19 pm
a little more info, please. What is your project? Give specifics if possible, and we can help with the code!
Thanks!

#### shaezi

#5
##### Nov 22, 2014, 01:13 pm
Of what?

could you please share with me arduino uno programming for calculating power factor........ input to the arduino will be current zero crossing and voltage zero crossing ( for this i use the zero crossing detector)....... both are square wave and have zero and one(e.g 5v). my load is three phase induction motor and i am working on single phase and control the rest of two with them.

#### charliesixpack

#6
##### Nov 26, 2014, 02:02 am
If you know the delay between zero crossings of current and voltage you need only convert delay to phase difference in degrees or radians to calculate the power factor.

#### ziakhan210545

#7
##### Dec 02, 2014, 02:58 pm
i have problem for finding power factor from zero crossing circuit through arduino i have achieve the voltage and the current signal through zero crossing detector now the problem is to calculate the delay between these two signal and calculate power factor from them
pleas help me in this programing

#### gremlinc5

#8
##### Dec 06, 2014, 05:19 pmLast Edit: Dec 06, 2014, 05:28 pm by gremlinc5
Um, I think you need a Fast Timer to understand Phase shift, if you want a PF with 0.01 precision your timer will need 50Hz of main * 100 = 5 kHz.

In that timer you will increase a phase shift variable.

With the square voltage cross you will activate an interrupt that put to zero the phase shift variable for next evaluation.

With the square current cross you will activate an interrupt that evaluate the PF.

With 50 Hz main you will get a 100 max value.
I think this is the phase shift so needs to be normalized to radians: (pi)*(phase_shift/100)

EDITED: you need (pi) and not (2pi) because you are using a zero crossing detector without knowing if that voltage or current is a positive or negative value

After calculate PF as cos(value_normalized)

Some suggestion? I hope it helps, if you are using it on a motor

#### Hemang_Upadhyay

#9
##### Mar 28, 2016, 08:41 pm
Hello.. I am new for arduino uno microcontroller. I am working on power factor correction of single phase inductive load. I need a code for power factor calculation, I am using zcd circuit for voltage and current.

#### MarkT

#10
##### Mar 29, 2016, 10:58 pm
timings gives you all you need to calculate the phase difference in radians, power factor is cos(phase_delay).
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

#### Hemang_Upadhyay

#11
##### Mar 31, 2016, 09:06 am
Hello sir actually i am working on TCR(Thyristor controlled reactor) so that i am also using peak detector   to sense 90 degree bcz in TCR SCR will conduct in 90 to 180 nd 270-360 interval. so my question is that can i use 2 ZCD and 1 peak detector with arduino uno microcontroller...??

Also in this case when my load will pure inductive at that time my current wave will be not pure sine wave so at that time zcd's result would be wrong..!!

give me a suitable suggetions

#### MarkT

#12
##### Mar 31, 2016, 03:34 pm
Then you need to sample at a high rate and sum up the power and calculate total power, rms
current and rms voltage.  power factor = true_power / (rms current x rms voltage)
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

#### Hemang_Upadhyay

#13
##### Mar 31, 2016, 09:26 pm
Thanks for your suggetion. bt In my project i am getting both the value of Vrms and Irms by using voltage and current sensing circuits but what about True power..?? How can i find it..??
Can you give me some coding of it..?

#### SathishNirmal

#14
##### Mar 10, 2017, 02:53 pm
i want to calculate the power factor using ardino.i need the code for this.
thankyou

Go Up