This post will go into details of the used hardware.
To connect the different sensors I build a “shield”. In the Arduino world a shield is an extension board that is plugged on top of an Arduino board.
The Arduino has most of the analog input ports, digital I/O ports and communication ports on headers located on the side of the board.
The sensor connection shield I build to connect the different sensors is plugged into these headers.
For the current measurement 2 CT (current transformers) are needed. One is measuring the current coming from the solar panels, the second one is measuring the house main line current. For calculation of the power the voltage is measured as well with a voltage transformer. I plan as well to mount a light sensor next to the solar panels. The light sensor will be connected with an i2c serial connection. But for now this is not implemented.
The Arduino analog input ports accept a maximum voltage of 5V. Therefor the analog signals must be adapted by a circuit to match with these specifications.
OpenEnergyMonitor has very good tutorials for connection the CT sensors (including calculation of burden resistors and calibration values) in their CT sensors – Interfacing with an Arduino building block. The only CT sensor I could find was a 100A type (YHDC SCT-013-000). As my currents are not reaching 100A, I re-calculated the burden resistors to match my requirements. For the main line I used a 165 Ohm burden resistor, which allows a maximum measurement of 20A which is more than enough for our house consumption. For the solar panels I chose a 330 Ohm burden, which allows a maximum of 10A, which is more than enough for a 1kW system. For calculation of the burden resistors please check the link to the OpenEnergyMonitor building block. Click on the picture below to see the circuit details.
For the voltage measurement circuit I found as well a tutorial at OpenEnergyMonitor. Check out the Measuring AC Voltage with an AC to AC power adapter building block. Instead of using a AC/AC wall plug I decided to get a cheap 220V/9V voltage transformer and integrate it into the box with the Arduino hardware. Click on the picture below to see the circuit details.
For the light sensor I chose a module from Adafruit. This module has the advantage that it has two sensors which are measuring the visible and IR parts of the light. The light sensor communicates with the Arduino over an i2C interface. The pins of the sensor are directly connected to the Arduino header pins.
The full circuit schematic is shown here. Basically it is not very complicated. Click on the picture to see the details.
That’s more or less everything about the electronics. Head over to the next post for the details of the electrical installation.