1. AardEnergy.


A Simple Plan

  • Measure current and voltage on single phase electrical supplies
  • Calculate electrical parameters like RMS, Real Power, Apparent Power, Power Factor, Frequency, THD, kWhr
  • Use Arduino Uno with an electrical metering chip for parameters
  • Use Arduino Due using software calculation of parameters

Kick Off

I’m new to Arduino but have used microcontrollers like PSoC4 and ARM Cortex-M3. Although my career has been more about hardware design I have written software, but would not claim to be a full time software professional.

I want to keep the voltages low on the boards to make them safe to handle, so no 240Vac mains exposure!

The current transducer needs to be an isolated type that can be clipped around an electrical feed wire. So it could be a Hall based sensor like LEM or a current transformer CT. I also want the set up to be cheap and available for other people to try out, the attraction of Arduino is the number of people learning about electronics and software. A bit of a survey turned up some CTs on Amazon which makes them readily available to all.

So the design decision at the moment is to use a CT for current measurement.

Voltage measurement also requires isolation. I’ve just spent 6 months designing an isolated amplifier for industrial applications, but it is too expensive for a low cost Arduino project and too complex. It is possible to buy plug in transformers with an AC output and I intend to use one of these as the source of a low voltage signal and isolated from the mains. It could also double up as a power supply to the finished project with some useful power up/down features for metering.

With all this in mind I bought some bits, starting with the Arduino. It was all a bit of a guess as I had no idea about the compatibility of Uno and Due parts or even whether they are the right parts for the job; so all a bit of a voyage of discovery.


The Uno uses an ATmega328P chip which is an 8 bit microcontroller. I am not expecting it to log waveform data in real time and do complex calculations. It does have an SPI port which will make it compatible with metering chips that do the calculations in real time and transmit the results to the Uno board. It has some EEPROM which is useful for kWhr retention when the power goes off.


The Due uses an Atmel SAM3X8E ARM Cortex-M3 chip which is a 32bit microcontroller. I am expecting to be able to log current and voltage waveforms in real time and do some calculations without any need for a metering chip. EEPROM storage may need to be external, not yet sure if the internal memory is accessible for data.


I’m expecting to build any additional circuits onto a prototype board, not one of the plug in type panels you see in Arduino kits.

A display will be a useful thing, rather than relying on a PC display of results.

Shopping List

With all these things in mind I sent off a shopping list to Farnell and received some parts.

  • Arduino Uno 2075382. Neat little board, clear silkscreen, ready to go. No product data came with it, just a guarantee and a sticky label telling me to visit Arduino.org.
  • Arduino Due 2250861. Another neat board, bigger than the Uno, clear silkscreen and ready to go. No product data just the same sticky label.
  • Prototype Shield 2075345. A prototype board compatible with the Uno but not the Due. Did not know whether to expect the Uno and Due to have a common footprint. Have yet to identify the prototype board for the Due.
  • TFT LCD display 2360852. Okay, well this board is not directly compatible with either the Uno or Due

So a bit of a “lesson learned”. Arduino boards are not compatible across types and not all that clear at time of purchase.

Shopping List 2

The prototype shield for the Due appears to be the PROTO BOARD, ARDUINO MEGA, REV 3 Farnell 2285197.

And the LCD display is compatible with the Arduino Esplora Boards. But there is a tutorial to help you connect to other types of board. https://www.arduino.cc/en/Guide/TFTtoBoards . Could be mounted on a prototype shield for each type of CPU.

To provide a low voltage AC measurement, a plug-in transformer should work, Farnell 2112026.

At Farnell the lowest cost current transformer that clipped onto the cable was 1797760, a 50A device at £37.61. From Amazon the SCT 013-030 is a 30A device that costs £8.75.

Do I need to buy a book? For now I’ll rely on the Arduino website…

Parts ready for set up


Arduino Boards


Next Steps

…down load the Arduino software and power up the Uno and Due.





  Big question, how do I debug the software? Is there a JTAG interface for debugging with breakpoints? Am I too optimistic?

Next Blog:-

2. AardEnergy – Set Up Uno and Due

3. AardEnergy – Current and Voltage Transformers

4. AardEnergy – Metering Chips


Peter Cox-Smith, 23 Nov 2015