EmonTX Firmware Questions

Hi All,

Ive recently completed a build of the EmonTX (previously using Mains Non-Invasive V3).

After looking through the various firmware options I've been using the following firmware https://github.com/openenergymonitor/emonTxFirmware/tree/master/emonTx_1CT_Voltage

as I wish to monitor both voltage and current (one CT). To do this im using a 9v transformer to measure mains voltage. However, my values are off by quite a bit.....for example the EmonTX output monitored via its serial port (real, apparent, VRMS, IRMS, supplyV)

7.59 82.53 343.41 0.24 3164

In relation to the firmware above - could anybody explain the numbers in the calibration code here...

emon1.calibration(357.6,126.5,0);
  emon1.calc(20,2000,vcc );

I think I need to substitute these for my own. Im also confused as the previous V3 firmware had declarations for the number of CT turns, burden resistor value etc. to calculate the scaling factor - none of these are mentioned in the firmware above. Thus, where my mains voltage is 240V (238V at present) the EmonTX is returning 343.41.

In addition, I have the CT connected at present to channel 1 (changed code to reflect this), however there is no wire through it at present so it cannot be reading any current. Yet however, Im showing an apparent and real power measurement. Obviously this would introduce errors into the system at times whereby voltage is being measured byt current consumption is zero or practically zero. Indeed with the above example the current consumption is nearly 0 at 0.24a but still the power calculations are off.

I am using an SCT-013-000 CT  - it came with the EmonTX kit. Anybody know how many turns is on this CT?

Thanks in advance for your time - hopefully somebody can shed some light on this - or explain how I can calibrate the EmonTX properly.

 

Kind regards

Gerard Gallagher

glyn.hudson's picture

Re: EmonTX Firmware Questions

Hi Gerard,

Sorry for the slow reply, I've got round to doing some lab testing today to investigate the problem. 

The problem was caused by a new batch of AC-AC adapters we are using (new adapters are better, the don't have a +2V offset see: http://openenergymonitor.blogspot.com/2011/12/ac-ac-adapters.html), the calibration in the code was not updated to reflect the change. 

The new code is as follows:

The voltage examples on github have been updated and the Single CT Voltage example has been made to work with Arduino 1.0

emon1.setPins(2,0);                    //emonTX AC-AC voltage (ADC2), current pin (CT2 - ADC0)
emon1.calibration(234.89,126.5,1.7);   //voltage calibration , current calibration, power factor calibration
emon1.calc(20,2000,vcc );              //No.of wavelengths, time-out , emonTx supply voltage 


 

gg339's picture

Re: EmonTX Firmware Questions

 Hi Glyn,

Thanks for the reply.  I'll give that a go. 

However I'm not using one if your tx's- rather one I had lying around

Would you mind at your convenience just explaining How you arrive at the calibration figures so I can recalibrate for my tx if necessary. 

Kind regards

Gerard

 

glyn.hudson's picture

Re: EmonTX Firmware Questions

 I came up with the calibration values be comparing the power reading, voltage reading and PF reading with a plug-in energy monitor and a bit of ittrative trail and error. Basicly just change the calibration values untill the energy monitor readings match what the plug-in monitor reads. 

I calibrated the voltage first, then current then PF. 

New calibration value = (Old value/ new value) * current calibration coefficient 

emon1.calibration(voltage cal , current cal ,PF cal); 

gb095666's picture

Re: EmonTX Firmware Questions

The way I calculated the calibration figures was to first of all change the defaults to emon1.calibration(100.00,100.00,1.0); and took note of the figures coming out of the serial monitor, at the same time used a plug in energy monitor to obtain the actual figures being used.

Take for example a Hair Dryer I had, the figures coming out from the serial monitor was VMRS = 105.89, IRMS = 6.89, the plug in monitor gave me Volts = 241 and Amps = 8.42, using that I can calculate the calibration figures.

( Volts * 100) / VRMS = Calibration figure , which is  ( 241 * 100) / 105.89 = 227.59

( Amps * 100) / IRMS = Calibration figure , (8.42 * 100) / 6.89 = 122.20

The reason I was 100.00 as the initial figure and not 1.0 was is gave me better precision in my calculation.

In order to calculate the Power Factor you need to add "powerFactor1 = emontx.real1 / apparent1;" in the Measure from CT1 section and print out the variable in the serial_ouput section using "Serial.print(powerFactor1);"

If you then do the same for other household items such as Vacum Cleaner, Iron, Heater, Fridge etc you get a range of figures but all should be roughly in the same ballpark, my voltage figures were between 227.59 to 230.55, all I did was take the average to get the figure I went with.

As Glyn says there is a bit of trail and error involved, but you can get pretty accurate, for instance my setup is within 5 watts of what my solar inverter is saying its generating.

Hope that helps

 

gg339's picture

Re: EmonTX Firmware Questions

Hi all,

 

Thanks again for your comments - Ive followed the procedure as above and found that the device is now calibrated to the correct readings. A little trial and error was indeed required.

Thanks again for your time

 

Regards

Gerard

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.