Forum - MCS Electronics

Author Message
Paulvk

Joined: 28 Jul 2006
Posts: 1197
Location: SYDNEY

Posted: Tue Jul 14, 2020 12:36 pm    Post subject: Power Factor calculator

In AC circuits it is necessary to measure power factor to determine
actual power being used, its normally complicated thing to do.
But there is a old way with meters , resistor and pencil and paper
with help from a calculator to save paper.

Note resistor value only needs to be large enough to get a reasonable reading
its value is not used.

So I thought why not use an AVR even bascom simulator.

I will put together a circuit with an AVR when I get time.

Regards Paul

this is a diagram:

This code provides the power factor from measurements

 Code: \$regfile = "m1284pdef.dat"                                ' specify the used micro Const Xtal = 20000000                                       'use constant for baud rate \$crystal = Xtal                                             ' used crystal frequency \$baud = 9600                                                ' use baud rate \$hwstack = 100 \$swstack = 100 \$framesize = 150       Dim Cos_phi As Single       Dim U1 As Single        Dim U2 As Single         Dim U3 As Single         Dim A1 As Single          Dim A2 As Single           Dim A3 As Single            Dim A4 As Single         U1 = 230         U2 = 8         U3 = 225 'Cos_phi =((u1 * U1) -(u2 * U2) -(u3 * U3)) /(2 * U2 * U3)         A1 = U1 * U1         A2 = U2 * U2         A3 = U3 * U3        A4 = 2 * U2         A4 = A4 * U3            Cos_phi = A1 - A2             Cos_phi = Cos_phi - A3             Cos_phi = Cos_phi / A4 Print Cos_phi End
Printpix52

Joined: 18 Jun 2014
Posts: 226
Location: D.F.

 Posted: Wed Jul 15, 2020 2:37 am    Post subject:
 Display posts from previous: All Posts1 Day7 Days2 Weeks1 Month3 Months6 Months1 Year Oldest FirstNewest First
 All times are GMT + 1 Hour Page 1 of 1

 Jump to: Select a forum BASCOM AVR/8051----------------BASCOM-AVRBASCOM-8051BASCOM-ARDUINOShare your working BASCOM-8051 code hereShare your working BASCOM-AVR code hereBASCOM BETA-SLA BASCOM Related----------------EASY TCP/IPAVR-DOSAR7212KokkeKat FAT-free SD card libBASCOM Project Blog Other Stuff----------------VariousPCB'sRoboticsNew WebSiteAnnouncementsAVR Archive----------------BASCOM-AVR ArchiveBASCOM-8051 ArchiveBASCOM-AVR Unsupported versionsEasy TCP/IP ArchiveBASCOM-EDB
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum