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??
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);
}