Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to calculate energy in kWh for DC energy measurment in MikroC

Status
Not open for further replies.

swethamenon

Member level 4
Joined
Sep 12, 2012
Messages
70
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,745
In MY PROGRAM FOR DC ENRERY MEASUMENT,have some doubt
voltage in V& current inA
so power in Watts.
each second sensing v& i.
1watt=joules/sec
so to convert into kW/hr(will be a small value).say if joules/sec reaches --(how much value) convert to kWhr.
How to code for this??

HTML:
adcval=Adc_Read(0)*.0048;
adcval1=Adc_Read(1)*.0048;
Is=adcval/330;
I=Is/2.5;
V1=I*5000;
floattostr(V1,val);
val[5]='\0';
lcd_out(1,3,val);
Is1=adcval1/330;
I1=Is1*1000;
floattostr(I1,val);
val[5]='\0';
lcd_out(1,11,val);
power = V1 * I1;
//floattostr(power,p_val);
//p_val[5]='\0';
//lcd_out(2,3,p_val);
energy =(energy + power);
floattostr(energy,val);
//val[5]='\0';
lcd_out(2,3,val);
delay_ms(1000);
}
 

P = V * I = I^2 * R

P (in Watts) = V (in volts) * I (in amperes)

E (in joules) = P (in watts) * T (in sec)

Eg: 40 watt lamp is ON for 1 hour

E = 40 watt * 3600 sec

= 14,400 joules

Power in Kilowatts

6Kw + 4Kw + 3 * 100 watt

= 6 Kw + 4 Kw + (100 * 3) W

= (6 + 4) Kw + 300 W

= (6 + 4) Kw + (0.300 * 1000) W

= 10 Kw + 0.3 Kw

= 10.3 Kw

Energy in Kilowatt hours = Power in kilo watts * time in hours

= 10.3 Kw * 10 hours

= 103 kilowatt hours (kWh)


You have to calculate E every 1 sec using

E (in joules) = E + (P * T)

1 joule = 2.77777778 * 10^(-7) kilowatt hours



eg: if E (in joules) is 10000000 then

E (in kWh) = E (in joules) * 2.77777778 * 10^(-7)


= 10000000 * 2.77777778 * 10^(-7)

= 10^(7) * 2.77777778 * 10^(-7)

= 2.7777778 kWh
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top