Hi friends,
i trying to measure power factor using 89c51 but the results are not stable. i simply started timer on first interuppt and stopped on second and then caculated, but the results aren't too good. i mean they are not too stable some times they show proper value sometimes wrong.
can anyone please share some code for the same.

Thanks