I have used the 2 channel non invasive sketch, to build a device which monitors how much power is being used in the home, and how much  power is being generated by the solar panels. If I am generating more than I am currently using, then the excess power is diverted to an immersion heater - to heat domestic hot water. This is a better option than it flowing back to the grid for which I don't get paid (solar renta roof).

This was a steep learning curve as I have never worked with a microprocessor before, but great fun and a great sense of acheivement when it actually works!

PCB

The first version was built on a Arduino Uno board, with the input components mounted on veroboard, but then I decided to build it as a standalone, with everything on one board.
The LCD is reclaimed from an old alarm keypad, and I had a USB panel socket laying about so I used that for the 4 CT input connections. (did I mention that I am a Yorkshireman...)

As the peak solar  power generation is 3.5kw, I used a shunt resistor to range up to 5kw, but fitted clamping  diodes (Glyn's idea - see forum) to ensure that the mains usage did not exceed 5kw and damage the Atmega chip.

fitted in box
 

With a bit of sawing and hacking, managed to fit the PCB into a Maplins project box.

power readings

Here you can see the power results, which if less than 1kw displays in watts, otherwise kw's.

The tiny LED is multi function and indicates;

1) flashing every 4 seconds - indicates that the unit is functioning, but not enough solar power to activate either relay.
2) steady but lit 25% - indicates that 500w is being unused, and activates relay 1, with a diode in series to limit the load to 500w (yes it does work, I've done the sums on the leccy meter!)
3) steady but lit brightly - indicates that in excess of 1kw is being unused, switches off relay 1 and activates relay 2 which delivers a full kw (which is the rating of the immersion heater).

The button is a menu navigator, and switches between displays (copied from another project).

kwh
 

This display shows how much power is generated within a 24hr period, before resetting back to zero at midnight. There is no external timing here, just a simple millis() counter which resets every 24hrs. On startup, the counter resets after 12hrs for one occassion ( so if it's powered up at midday, it will  reset at midnight and every midnight thereafter.

This display shows voltage and power factor, which of course is needed for calibration purposes.
To calibrate it, I took the readings from the LCD, removed the chip and wrote the new sketch via a Arduino Uno board, before replacing it in the standalone.

The sketch is posted here , please feel free to make any suggestions or create a new version of the paste in pastebin., and although a new guy to Arduino's/programming, if I can help, please email me at (the last word in bold in this post) @gmail.com

Sketch has also been uploaded to OpenEnergyMonitor. Download it here

...UPDATE 7th Sept

Following Glyn's advice (in comments below) I have built a Nanode, and have connected both units via their Rx/Tx serial bus, and use a simple Serial.print statement in the above device, to be decoded in the Nanode by the CmdMessenger library.

Data is then uploaded to Pachube every 20seconds by the Nanode, provided that the data values have changed.

 

Many thanks to Trystan & Glyn

yorkshirepudn

Please post any comments and questions about the Solar PV Manager system to the forums

 

Guest's picture

Re: Solar Power Manager

Hey that's a really good idea which will solve the problem I have. My PV connects to the existing consumer unit, so while I can measure PV current (inside the consumer unit) and grid current (meter tail), I can't measure house current so have the problem of working out the direction of the grid current. I had been thinking about comparing its phase with the PV current, but much simpler is just to put the PV feed through the CT on a meter tail, thus giving me house current (grid current minus PV current).

Paul Reed's picture

Re: Solar Power Manager

To keep the supplies seperate, I fitted a Henley block close to the electric meter, and fed a fresh pair if tails from the block directly into a dual gang consumer unit, which in turn powered the immersion heater. This Henley block also joined the feed from the solar invertor. So I could easily isolate and pick up on any of the tails before they were joined in the block.

If it helps, here is the front-end circuitry, and you will note the 2 clamping diodes to ensure that over/under voltage doesn't damage the chip. I felt that this was important as I have used a high value burdon resistor to read only 0 - 5kW (as I have a 3.5kW solar panels).

As regards the veroboard layout, I sketched it out rough on some graph paper and made a few tweeks as I commenced the build, for example; I wanted a vertical variable resistor, but could only get a horizontal on the day, so had to shoehorn it in. I also found that I had a little more space so I added a bit of space to allow future amendments. But here is a scan of the sketch if it helps. If you look at the sketch and then look at the photos of the PCB I'm sure you will figure it out.

The Atmega chip was sourced here.

Steve Knight's picture

Re: Solar Power Manager

Thanks Paul, thats a great help, I'm going to totally rebuild now! but I will keep the Triac as my control method, I run it as low as 200 watts, which on a dull day still gives me a reasonable amount of hot water!
Anyway, thanks again for the drawings SK