Revision Log
Changes since last version
Electronics
- 2x 10uF bias stabilizing capacitors added significantly improving accuracy: more info
- Changed Voltage measurement circuit
- Power for arduino comes from a seperate transformer to AC voltage measurement transformer.
Software
- Arduino sketch rewrite, sketch now follows Atmel's 465 appnote method, adding:
- Phase calibration
- Digital high pass filter to remove offset.
Other
- Much simplified calibration
Other versions
Previous versions
Further Development questions
Update by Glyn Hudson (16/06/11): Diode clamping / over-voltage and static protection In the current Mains non-invasive 3.0 and emonTx circuit design, if the current being sensed by the CT clamp sensor exceeds a certain limit (depends on CT turns-ratio and burden resistor value) the Atmega analogue input voltge will go outside the range 0 to Vss. This could potentially damage the chip. In this forum post I investigate how the voltage input can be clamped to a safe range using diodes and look at what protection mechanisms are built into the Atmega328 and how best to utilize them.
This project is work in progress, there are probably improvements that can be made to the current design and certainly experiments to be done!
Here are a couple of lines of inquiry that may be interesting to look at to get to the next stage. I may get time to look at some of them but probably not every line so please feel free to take any of them up and if you have any suggestions as to the best way to go, it would be great to hear them! A few further development question:
-
One of the main differences between version 2 and 3 is that the voltage measurement in version 3 is done on a separate transformer to the transformer used to power the arduino. I think this may be the simplest solution to the problem of non correct voltage measurement caused by trying to measure voltage from a floating bridge rectifier supply as I was doing in version 2. To start with one of my main motivations for trying to incorporate power and measurement in the same adapter was the price of the adapters I had seen. I had a further look around for cheaper adapters and found that farnell have adapters at around £3.00 each and AC-to-AC one and a AC-to DC one. At this price going for two adapters does'nt seem like such a bad idea. The cost of the bridge rectifier and smoothing capacitor for the one adapter version came to £1.48 so the saving is not that large. Having two adapters though is a little more bulky and so that is a drawback. For version 3, I thought it would be simpler and more accurate at least for the time being to go for the two adapters, however I am still interested in looking at a one adapter version and so I think it would be good to:
- Characterise the difference between circuit version 2.0 and 3.0 properly.
- Investigate center-tapped power supply design and half wave power supplies as used in Atmel's AVR 465 appnote: both allow for fixed ground.
-
Atmel AVR 465 app note uses a programmable gain stage to increase accuracy at lower currents, that could be an interesting addition. It would improve accuracy but at the expense of simplicity...
-
Testing of 3-wire single phase implementation. Done, just need to write it up.
-
Measurement of AC voltage quality as in this eg. http://www.kmitl.ac.th/~kswichit/PICTHD/picthd.htm
Are there any other further development questions? Any suggestions would be very welcome.
Inspiring Project
Glyn/Trystan, thanks for developing this project, it's renewed my 40 years interest in electronics!!
I am currently using the 2 channel version to monitor generated solar power and current home usage. If I have surplus power then it diverts it to an immersion heater to heat my domestic hot water.
With help and guidance from another forum member, I have introduced hysteresis to increase stability when switching the load, attached a LCD display so I can see the power status, and so far the testing is going well.
The only thing that I am struggling with is setting the Power Factor. I have read the blog (several times!!) but still not sure how to get it right. I am comparing it with Maplin plug-in monitor, and if I get it right for one load, I have to adjust it again for another, and so on.
pastebin.com/u/rossoreed
I just love this project,
I just love this project, waiting on my CT's to come in to get it all together. The programmable gain stage is a great idea, also what about measuring the quaility of AC voltage as in this eg. http://www.kmitl.ac.th/~kswichit/PICTHD/picthd.htm it would sure add a very nice feature.
Hey MarkC, thanks a lot for
Hey MarkC, thanks a lot for the link, that would be really cool to do, I will add it to the list of development questions/directions.