Solar Energy Management

 Rather than allowing my generated Solar Power flow back to the grid, I want to build a unit which monitors;

  1. how much energy is currently being generated by the PV system
  2. how much energy is currently being used by my ring main
  3. if #1 is greater than #2, then the generated power is diverted to an immersion heater, to store the surplus power as hot water.

Would '2 channel non invasive 3' be a good starting point to achieve 1) and 2) above, and use ch1.realpower & ch2.realpower for calculating 3) above?

I am new to Arduino (having just ordered my 1st uno board from Ebay!) but would be grateful for any advice or pointers.

 

Regards

andysimm2000's picture

Re: Solar Energy Management

That is just what I am looking at doing - not got the PV system yet but wanting to get things ready. (will be ordering ~3.5kw system very shortly :) )

I am thinking along the lines of switching a remote control socket so that you can use the extra power to power a fan heater.

Perhaps even having several outputs so that it turns first on (immersion heater), sees if there is still extra power (stat may have cut out or generating a lot!), if extra power then turning on another remote load (fan heater or even a air con for the summer).

Now to study the forums... Hope we can develop in parallel Paul!

Andy

phil666's picture

Re: Solar Energy Management

 

Paul,

I'm also looking to do a similar project and will be very interested in any other comments on this discussion.

Your point 2, measuring the house power consumption, note that this value might be negative if you are generating more than you are consuming. You will need to detect when this value is negative so that you know you are utilising your energy and not that from the grid.

I believe you therefore need to look for a current sensor that can measure AC power direction and not just its absolute value.

I have heard that Hall effect current sensors, such as Honeywell's CSLA2CD http://uk.farnell.com/jsp/search/productdetail.jsp?sku=1082269 can be used to measure AC power and direction, but I'm not sure how to make it work. Anyone got any ideas?

I have also been advised that I could configure a passive current transformer probe in a similar manner to an SWR meter to read power direction.

Regards,

Phil

 

 

Paul Reed's picture

Re: Solar Energy Management

 > ... note that this value might be negative if you are generating more than you are consuming

Not necessarily,  it depends where the measurement is made, and how your home is wired.

In my case, the solar feed is tapped into a Henley block situated between the Meter and the consumer unit, so I can monitor household usage after this connection  - which will always be positive, and measure Solar  power before the Henley block which again will always be positive.

Similarly, my Immersion heater is on a separete circuit and again feeds into the Henley block, so power drawn by the heater will not influence household usage.

So to use an example;
I have a kettle drawing 1kw from household usage (hu)
I am generating 2kw Solar Power (sp)
A little maths, (sp) - (hu) = 1kw spare to be utilised by the immersion heater

I am hoping that the maths can be done within the software, including hysteresis, ect.

I have already built a similar unit, using op amps and a comparator chip, which works very well albeit a bit crude, and am hoping that through Arduino, I (we!) can develop something more accurate and flexible.
But, as I have already said, I'm new to Arduino, and hoping for a little support and guidance from those more knowledgeable than I am!

gr0mit's picture

Re: Solar Energy Management

I've already got this working!!!!

I bought a phase angle controller which I drive from the arduino output PWM pin, which uses PID control to track PV output and dump exess heat into my hot water tank.  I have a pair of CT feeding two analog ports exactly as per the openenergy monitor, with a few tweaks.

 

Whole thing needs a bit of adjustment as I seem to get a little bit of leakage back into the grid (meter still running backwards a little) but the principle seems sound, and responds to step responses very fast (i.e. kettle going on, cloud overhead etc)

 

If anyone interested please let me know and I can post the code.

 

Rgds

Tim Robinson

Paul Reed's picture

Re: Solar Energy Management

 Yes, please post the code Tim, I am also thinking about using a phase angle controller, so any help/advice that you can give will be very much appreciated.

 Paul

Amin Zayani's picture

Re: Solar Energy Management

 Hi, your project seems (relatively) easy to implement, Tim confirms it from experience.

I think it would be more convenient to use multiple resistors to heat the water (I've seen a similar system at SMA here in Germany, they have a tank (maybe 10-12 cubic m) with 16 resistors that are controlled by relays. That gives you 16 steps.

If you have just one resistor in your heater maybe you should consider a mosfet? (a big one), but the logic with arduino should be straight forward. 

You could code it to dump exactly the excess electricity and not more into the heater.

Hint: for better performance you should monitor the actual immersion heater consumption and compare it to what you're calculating should be fed

Interesting project though... good luck with it ;)

PS: what's the inverter in your PV system?

gr0mit's picture

Re: Solar Energy Management

#include

//Basic energy monitoring sketch - by Trystan Lea //Licenced under GNU General Public Licence more details here // openenergymonitor.org // modified by Tim Robinson to include PID library //Sketch measures current only. //and then calculates useful values like //apparent power and Irms. //Apparent power is calculated from set Vrms. double Vrms=240.0; //Setup variables int numberOfSamples = 1000; //Set current input pin int In_pv = 1; int In_used = 0; int analogOutPin = 9; double time; // values for samples = 2000 //double Kp = 0.08; //double Ki = 0.3; //double Kd = 0.000; // values for samples = 100 double Kp = 0.03; double Ki = 0.3; double Kd = 0.0005; //Current calibration coeficient double ICAL_used = 0.15007; double ICAL_pv = 0.1529; //Sample variables int lastSampleI_pv,sampleI_pv,lastSampleI_used,sampleI_used ; int heater_power; //Filter variables double lastFilteredI_pv, filteredI_pv; double lastFilteredI_used, filteredI_used; //Power calculation variables double sqI_pv,sumI_pv; double sqI_used,sumI_used; //Useful value variables double apparentPower_pv, Irms_pv; double apparentPower_used, Irms_used; double export_pwr; //Define Variables we'll be connecting to double Setpoint, Input, Output; //Specify the links and initial tuning parameters PID myPID(&Input, &Output, &Setpoint,Kp,Ki,Kd,DIRECT); void setup() { Serial.begin(115200); heater_power = 0; myPID.SetMode(AUTOMATIC); Setpoint = 0; } void loop() { for (int n=0; n

gr0mit's picture

Re: Solar Energy Management

OK the paste below is unreadable, so here is the complete sketch again:

 

http://pastebin.com/FiWSqHFC

 

 

Paul Reed's picture

Re: Solar Energy Management

Many thaanks for the code Tim.

Sorry if it's a stupid question, but what is a  PID?

gr0mit's picture

Re: Solar Energy Management

It is a standard method for optimising industrial control.

 

Below are some pics of my prototype!  The Phase angle controller is http://www.farnell.com/datasheets/460918.pdf

running in mode 2.

 

 https://picasaweb.google.com/lh/photo/gJgCQzsvbIXRQIEjpDkahNYD_UXIQTVZjWj_TjWU0iI?feat=directlink

https://picasaweb.google.com/lh/photo/yqa4YasHRFT53uyGZ0idU9YD_UXIQTVZjW...

https://picasaweb.google.com/lh/photo/f_8BBXcnNvWlheB__CaU29YD_UXIQTVZjW...

 

 

Delapeyre's picture

Re: Solar Energy Management

I have had this system running for quit some time, I went the industry route and installed a  plc,and monitored generated power versus consumed and controlled the boiler and underfloor heating to make sure only limited power is returned to the grid.

The software is simple and easy to use and you can tweak it on the labtop at a moments notice!! plus its industry standard equipment no need to try to start adding noise filters and transient clippers and rubish, just design install and write software and go!

Paul Reed's picture

Re: Solar Energy Management

 Can you post the software please.

 

Paul

Delapeyre's picture

Re: Solar Energy Management

We are using the Crouzet Plc range so the software is bespoke for that range of PLC.
Look at the link
http://www.crouzet.com

Grm's picture

Re: Solar Energy Management

Hi Paul,

This looks very intersting and is the sort of thing I plan to do. I wondered why you use mode 2 of the PID, I would have thought you would have to use mode 1 - phase control.

I was considering building a phase controller but this looks and easier (but more expensive) option.

Graham

 

Paul Reed's picture

Re: Solar Energy Management

Graham, I'm not using a PID, it was gr0mit who mentioned using a PID in mode 2.

Being a Yorkshireman, the price of a PID put me off using one, they are too expensive, and it would take many years of use to get the initial outlay back.

I am currently exploring using 2 (or more) outputs from the Arduino, one which supplies full power (in my case 1kw) and a second output which provides 500w via a thyristor. So on dull days, maybe I'll manage the 500w, and if the sun comes out then the Arduino will activate the second 1kw output.
Just a thought based upon  the post above by Amin Zayani re his experiences in Germany with SMA.

The cost of a simple Thyristor circuit set at 50% output is insignificant compared with a PID, even if using 2 or 3 outputs (1kw, 2kw, 3kw).

I am taking this project one step at a time, and am currently trying to get the 'front end' working first. Once I get a reliable and accurate measurement by the Arduino, then I will look at how best to turn the calculations into power output.

 

Robin's picture

Re: Solar Energy Management

Hi,

Speaking as a mechanical engineer with a somewhat limited knowledge of electricity, I am not sure that a thyristor is the correct way to control our variable loads.

Let's say we are generating 500W of electricity that we want to use, and we have a 1kW load with a thyristor control.  The thyristor will limit the power in the load to 500W, but it will do that by giving 1kW for half the time.  So we might end up paying for some of the power, specifically 500W for half the time.

It seems to me that we need loads with a sinusoidal current waveform - the same as that produced by the inverter - so that the power factor is close to 1.

Is there an expert out there who could confirm this (or otherwise!) please?

If I am right, the correct way to go is to use a number of switchable loads, with relays.

Finally, one more thought: another way to soak up surplus electricity might be to use a storage heater.

Regards

Paul Reed's picture

Re: Solar Energy Management

Robin, this was my original thought too, but it appears that the household electric meters don't record peak usage, but average it out over the complete cycle (or 180 deg) so it doesn't actually record it. That's the experience of other forums too, who do use thyristors for similar use. Paul

Robin's picture

Re: Solar Energy Management

Thanks for that, Paul.

They recently replace our old meter (with the rotating disc) with a new one, which is a small black box - so it's hard to know what goes on inside it.  Except that when the PV cells are producing, it gets a bit grumpy and refuses to run in reverse.

Paul Reed's picture

Re: Solar Energy Management

Robin, see post #64 bit.ly/jZK1hT for the on-going discussions we had about how power usage is recorded re Thyristors (I use the same forum member name as on here).

Delapeyre's picture

Re: Solar Energy Management

Use one of these

Proportional power controller2-10Vdc 40A

RS Stock No. 218-1892

They work perfectly

 

Regards

Mark

Paul Reed's picture

Re: Solar Energy Management

 Not at £85 each!

Delapeyre's picture

Re: Solar Energy Management

LOL yes they are at first apearance expensive, But they are safe easy to use you dont have to re invent the wheel, and your feed in tarif with the project soon pays it off.

Building your own pcb and equipment is what i have always done but when it comes to burning your house down, its better to use trusted well developed sturdy technology.

But have fun anyway LOL

stuy4u's picture

Re: Solar Energy Management

How did you get the 0 - 10v output to control the Phase angle controller?

Did you use an op amp?

Stuart.
 

Tampa Solar's picture

Re: Solar Energy Management

I am working on a similar track, likely with slightly different priorities/goals, but common tactics.

Got 10kw pv, on-grid system running. Want a way to harvest the output, off-grid too, i.e. extended grid outage.

My diversion load would be a water heater too, with a phase-angle controller. My design thoughts are to have a voltage threshold, i.e. the heater kicks in at 250 vac and higher. The goal is to keep the grid-tie inverters happy by sucking the excessive energy with a real-time response.

Above all locking and tied to a 48v battery based 240vac inverter that is a few kw in size. Panels kick in with the reference from the standalone inverter and the diversion load allows for load changes and pv variations.

sara dot j at embarqmail dot com

Your thoughts please.

Mr. Sharkey's picture

Re: Solar Energy Management

Interesting, although a bit on the expensive side (USD$169.20). Also, I checked several suppliers and there seems to be no stock available at this time.

There are several models available, from 15 - 90 amps capacity in a couple of input ranges. Here's the data sheet: http://www.crydom.com/en/Products/Catalog/p_cv.pdf

AndySV1K's picture

Re: Solar Energy Management

 Hi chaps,

I'm on the same path as you lot and probably scratching my head in the same way too.

I came to very simliar conclusions to the above but on my own so this must be the right way to go!

What do you think about this for a phase angle controller?....

 

uk.rs-online.com/web/p/power-misc/3796518/

 

It's not too badly priced.

 

Andy.

AndySV1K's picture

Re: Solar Energy Management

 ...and just found it from the manufacturer even cheaper!....

 

www.united-automation.com/pac2/

 

Andy.

stuart's picture

Re: Solar Energy Management

Well done, this is now getting more interesting!

 

Found this one as well..

http://www.united-automation.com/psr-25/

£41.90

 

Looks like you need a fairly large heat sink as well 100x100x3mm

 

AndySV1K's picture

Re: Solar Energy Management

 I ordered the 0-5v version the other day.  Havnt heard back from them yet and when I logged in to chase my order it appears it may be out of stock.

I have written a basic arduino test sketch to run some testing with this when i get it so will update when i know more.

 

Andy.

stuart's picture

Re: Solar Energy Management

These devices also look like they would do the job, £22 each.

http://www.united-automation.com/ual-csr-604b/

Just need to vary the resistance to drive up to 15A @ 240v

 

Paul Reed's picture

Re: Solar Energy Management

 I doubt that this could be used, as it needs a high voltage trigger.

Ideally, we need a 0 - 5V trigger to control the output.

stuart's picture

Re: Solar Energy Management

Andy, did you get your controller ?

AndySV1K's picture

Re: Solar Energy Management

No, in fact ive just asked for a refund as they are waiting for parts to build these and can get no estimated date of delivery.

When he mentioned that it could 6-8weeks, or it could be longer, i gave up and asked for refund.  Back to the drawing board!

Not that they are not good to deal with, they were very apologetic about it and were very helpful in general, just couldnt get it to me anytime soon.

Will have to start looking for an alternative.

 

Andy.

stuart's picture

Re: Solar Energy Management

I've since found this model which I think may do the job...

http://www.tmswebshop.co.uk/buy/Solid-State-Relays-SSRs.html#aPROSWITCHP...

Low Cost Phase Angle Control SSR, 75A, 4-20mA

Product Code: PROSWITCHPA75LC

Price:   £48.00

single-phase solid state relay, with phase angle control for resistive loads up 75A, controlled from a 4 - 20mA (proportional) input. At 4mA the output is off, at 20mA it is fully on, in between it will be partially on (i.e. reduced power). They are designed to be mounted on metal panel walls or other heatsink in order to keep the temperature of the metal base below 40°C. It has an LED indicator.

Load Voltage: 90 - 250Vac
Control Signal: 4 - 20mA DC (Proportional)
Dimensions (LxWxH): 62 x 45 x 23.5mm
Ambient Temperature: -30°C - +75°C
Dielectric Strength: 2000Vac
Insulation Resistance: 500M Ohm/500VDC

 

 

Googling for this item, turns up some other suppliers

http://www.multice.com/bp/Solid%20State%20Relay/SSR-25LA.htm

and lots, lots more from China etc.

 

and if you fancy ordering from Russia,

http://shophunter.eu/hu/prod_det.php?product=1527/2154/fotek_ssr25lah

They are 23 Euro.  (although their picture appears to be wrong)

 

madmurg's picture

Re: Solar Energy Management

I have just got my solar immersion controller up and running it is working great. It kicks in at 250 watts spare power and is proportional right up to 3 kw. I have attached a picture.

madmurg's picture

Re: Solar Energy Management

How do I attach a picture.

madmurg's picture

Re: Solar Energy Management

Paul Reed's picture

Re: Solar Energy Management

Are you using a 0 - 5V Crydom power controller?

If so, is it controlled by the PWM output from the Arduino?

AndySV1K's picture

Re: Solar Energy Management

looks good!

so how do we generate a 4-20ma control signal?

 

Andy.

madmurg's picture

Re: Solar Energy Management

I am using. 2-10v controller which is controlled with an arduino. This is powered by a 12v plug in charger, this is also used to generate the 2-10v via an electronic circuit which consists of a couple of transistors a diode a few resistors and a capacitor.

stuart's picture

Re: Solar Energy Management

Links...

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1270342266

 

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1283882387

 

wikipedia has some more info as well, look for "20ma current loop"

 

Possible circuits...

http://www.maxim-ic.com/app-notes/index.mvp/id/4483

 

madmurg's picture

Re: Solar Energy Management

stuart's picture

Re: Solar Energy Management

Are you firing the triac on zero crossing using this circuit ?

madmurg's picture

Re: Solar Energy Management

Analoguewrite 1 gives me full power which is 10v at the controller, analoguewrite 200 gives me lowest power which is 2v at the controller.

stuart's picture

Re: Solar Energy Management

Sorry I forgot, you're using a crydom variable output unit with a 0-10vdc range.

 

Phill W's picture

Re: Solar Energy Management

Hi Madmurg, you say that "Analoguewrite 1 gives me full power which is 10v at the controller, analoguewrite 200 gives me lowest power which is 2v at the controller."

Is this not the wrong way around? surely you want a fail safe system, if the Arduino goes down and supplies 0 at analoguewrite will this switch to full power?

 

I think I may go with this as my design, although the Crydom is expensive it is, as mentioned earlier, sturdy and proven.

A couple of other things:

Do you mount this on a heatsink? edit - The Crydom? If so how big?

What transistors and diode did you use?

 

Cheers

Phill

Phill W's picture

Re: Solar Energy Management

Hi Madmurg, you say that "Analoguewrite 1 gives me full power which is 10v at the controller, analoguewrite 200 gives me lowest power which is 2v at the controller."

Is this not the wrong way around? surely you want a fail safe system, if the Arduino goes down and supplies 0 at analoguewrite will this switch to full power?

 

I think I may go with this as my design, although the Crydom is expensive it is, as mentioned earlier, sturdy and proven.

A couple of other things:

Do you mount this on a heatsink? edit - The Crydom? If so how big?

What transistors and diode did you use?

 

Cheers

Phill

 

(Sorry guys, this is a 'bump' due to 'dollwin' trying to sell me smoked salmon that tastes like hardwood flooring apparently)

 

madmurg's picture

Re: Solar Energy Management

I was expecting it to work the other way round but it doesnt, I dont know why.

the transistors are P2N2222A NPN and the diodes are just basic diodes. the crydom unit is mounted on a metal box which acts as the heatsink, no need really as it doesnt get very warm at 3kw. the crydom is rated at 15a to 90a so at 90 amp it will get hot.

madmurg's picture

Re: Solar Energy Management

sorry its not rated at 90amp it is rated at 25 amp and a heatsink is recomended for loads over 13 amps.

Phill W's picture

Re: Solar Energy Management

Hi madmurg,

thanks for the reply.

I can see that you are feeding the second transistor from the power rail and when the first transistor is 'off' the power feeds into the base of the second. When you turn the first transistor on, the power dumps through it and does not turn on the second. (I'm sure there is a more tech way of explaining it :-) ).

Have you tested it to see what happens if the Arduino stops outputting to the transistors? Does the controller dump full power to the heater?

I suppose if the Arduino is fairly reliable this should not be a problem, worst case is that you get a tank of hot water from the grid and not the solar.

 

Could anyone, or you, say if feeding the output from the first transistor into the base of the second would do this so that analoguewrite low = no output on the controller and a high output turns it on?

Cheers

Phill

madmurg's picture

Re: Solar Energy Management

I have had my unit running 6 months now and no problems as of yet. If the arduino loeses power the crydom will not work anyway as the electronics are off the same circuit as the supply to the arduino.

Phill W's picture

Re: Solar Energy Management

Yeah I can see that, it was just a hypothetical question.... what if the Arduino falls over without the power failing? Does the Arduino self re-boot?

 

I did find this: http://www.nano-reef.com/forums/index.php?s=bae50dd670cce0744895c3a932cc...

Which changes the PWM signal of the Arduino to a smooth (er) 0-5V 'analogue' signal, then converts it to 0-10V  this will ramp the power up and down rather than firing it on/off lots... I think.

This is slowly coming together...... I may be ordering bits soon........ and borrowing an oscilloscope!

 

Anyone else got any input?

Paul I know you dont like the idea of an £85 controller, I'm prepared to go with it, mainly on known safety grounds and the fact that It will pay for itself in the end and allow me to use the maximum solar., what are your thoughts?

 

Paul Reed's picture

Re: Solar Energy Management

Phill, I think it's a great idea, and the way forward to make use of  spare power efficiently rather than having set benchmarks to reach as in my system. The main thing that bothers me is the Crydom price, and keeping the overall project costs proportional to the likely gains.

On sunny/bright day's, the Crydom is unnecessary because you will easily get a sufficient power margin from a relay system to heat the likely hot water demands. However, the Crydom will hold a significant advantage on dull days, especially winter, when it becomes increasingly difficult to find that spare power, as it can make use of even 100W of spare power, and heat the water over a longer period.
Today was a good example, as my unit diverted 5.8kWh of power to the immersion heater, which more than met demand, but if we have grey skies tomorrow, I might get nothing!

Someone (sorry can't find who it was just now) recently contacted me regarding using relays and a 'triple element' immersion heater unit, available here. The idea was to use a combination of outputs from the Arduino to achieve a wide range of power outputs, which could switch the elements to run in 'series' to meet low power outputs, or in parallel, individually or in combinations. All of which could be safely controlled via preset programming.
I thought that was a brilliant alternative idea, and would may be cost effective if you had to buy and fit an immersion heater anyway. 

Phill W's picture

Re: Solar Energy Management

Thanks Paul, a new immersion would only be an option if I tried to remove the 3kW element and replace it with a 1kW one...... and I twisted the copper!!!!!

Today I could have diverted 11kWh :-( ... Like you say on a grey day it might not amount to much, but as Tesco say (as they prise the last penny from your fingertips) 'every little helps'.

Do you have any idea if the link on the nano-reef board would be suitable for modifying the PWM from the Arduino?

Cheers again

Phill

Paul Reed's picture

Re: Solar Energy Management

I take your point with twisting the copper!! I had loads of stress removing the blank before fitting the 1kW element.

The circuit looks good to me at first glance, but if I were considering using it, I would test it in a simulator first.
I use LTSpice which is free, and by varying the voltage at Pin 3 (0 - 5V), you could plot the expected output at Pin 1 to ensure that it scales proportionally.
R6 & C2 convert the PWM to a smoothed DC voltage, which forms your 0 - 5V input to Pin 3.

Paul

stuart's picture

Re: Solar Energy Management

As per previous posts I'm trying to do this with a similar solution, only avoiding the high price of the Crydom unit.

Currently looking at alternative circuits to drive either a high voltage resistor circuit or an industry standard 4ma to 20ma  current loop circuit. 

The SSR units which support these features are normally around the £30-£40 mark, about half the cost of the Crydom.

I have a 3kW PV inverter so given the base load of my house (around 250W during the day) I'm never going to push the full 3kW into the hot water.

I don't want to change the 3kW heating element either, as its a new 310 litre tank - which also has solar coils in the bottom half - but I'm not using that at the moment but that has other interesting potential!  (http://www.vaillant.co.uk/homeowners/products/storage-cylinders/solar-sy...)

I like the idea of building a simple electronic device which people could use themselves without requiring plumbing skills.

Phill W's picture

Re: Solar Energy Management

Anyone know what the size of a mains current spike into a 3kW heater is likely to be?

RS are out of stock for the 40A Crydom controllers.......... the datasheet does not even have the 40A model listed, it goes from 25A to 50A, so I'm wondering if the 40A is being discontinued.

 

The 25A model is just over £13 cheaper, will it be meaty enough?

Datasheet says 250A surge for the 25A model, 625A for the 50A model

 

madmurg's picture

Re: Solar Energy Management

why do you need a 40a controller the max load of a 3kw immersion is no more than 13 amps.

Paul Reed's picture

Re: Solar Energy Management

Not sure what you mean by current spike? The heater element is a purely resistive load. Current spikes normally occur with reactive loads such as motors or high capacitive loads.

There will be a 'in-rush' current when first connected due to the element having a lower resistance when cold, but this is usually an increase of no more than 5% of normal load.

Anything over 13 Amp should be adequate (as per Madmurg's post)

stuart's picture

Re: Solar Energy Management

I've been trying to work out how best to tackle this project.  We already have several working solutions as mentioned in previous posts, but they are either 1. limited to stepped power outputs and/or need different heating coils.  2. require high cost proportional solid state relays.

I've been looking into using adjustable SSR's in the "cheap" range - something like this...

http://www.ebay.co.uk/itm/SSR-40VA-40A-Resistance-Type-Solid-State-Relay...

Less than £10 each, including heat sink (which may not be required for 3Kw switching).

 

The problem with these units is that you control them via a resistive load of 500kOhm to set the angle/voltage at which the SSR fires.  From several diagrams on the net I don't think this pin is optically isolated from the mains either.

 

Any suggestions on how to switch in/out a 500kOhm load (probably 240V @ 1W) ?

So far I've considered:

  1. digital pot - not seen any which handle 240v AC
  2. Resistive Optocoupler - some handle 240v AC but not at 1W (perhaps a couple of series?)
  3. Photo FET optocoupler - http://docs-europe.electrocomponents.com/webdocs/0b4f/0900766b80b4f817.pdf - not suitable for 240v mains
  4. Building my own Optocoupler using light dependent resistors - this has some possibility as 240v @ 500mA devices are available.
  5. Building a switching resistor network to digitally switch in/out a bunch of load resistors.

I'm coming to the conclusion that its not going to happen with this SSR device - but thought I'd like a second opinion from you folks!

Any one know of a high power/voltage resistive optocoupler ?

 

Paul Reed's picture

Re: Solar Energy Management

Have you seen this thread?

stuart's picture

Re: Solar Energy Management

Thanks for that link, I've not read that before.

The device the poster's using is the DA model from here... http://us.100y.com.tw/pdf_file/29-FOTEK-SSR-xx.pdf

Thats a straight forward on/off unit with zero cross detection, so the method he's employing is to simply switch on the unit, delay for a while and then switch it off.

What this will do in practise (I think!) is more like a manual burst fire method, which is not great for our hot water project because the power is not restricted by phase angle.

 

Paul Reed's picture

Re: Solar Energy Management

I'm not sure that burst fire is such a bad thing, because I understand modern electric meters calculate real power over a number  of cycles, and not just one.

I spoke with Siemens technical some months ago about this, and they confirmed that this was the case, although they would not tell me how many cycles it was averaged over, for fear of people trying to 'beat the system'!!

If we could find that out, it would be relatively a simple solution to fire 1 cycle in 20 (5% power), 10 in 20 (50% power) or 20 in 20 (100% power).

A big advantage with burst fire is that all of the switching is done at zero crossing, so less heat and interference/noise, and also can be very accurately metered (Crydom's are not totally linear in operation).

........just a thought!

Paul

stuart's picture

Re: Solar Energy Management

The other big advantage is that you can build a burst fire device from a cheap SSR.

Probably wouldn't make much difference if you just randomly switched the SSR on either as it would wait for the zero cross before switch on, although might make the accuracy of you're control a little off.

 

Diana's picture

Re: Solar Energy Management

If anybody is still interested in our PAC 25A as advertised on the link mentioned www.united-automation.com/pac2/, we do have an unforeseen problem with the manufacture of this product. We are working on sorting the issue and this could take between 2 and 6 weeks to resolve. Currently there is no guaranteed date for stock availability; but we do manufacture a large selection of controllers and there may be another option suitable for your application. If you are interested I am able to discuss it on here or you could contact us via our website www.united-automation.com/pages/Contact-Us.html.

AndySV1K's picture

Re: Solar Energy Management

just for info, I suggested that someone from united automation post something here, as I had a good chat with a couple of people there over the last few days and got some good info from them, I suspect they also have things to learn from members here too so good chance to collaborate.

I have no connection to the company whatsoever, I just searched for their name after seeing one of their products on the Farnell site.

I've just ordered an EVR 4kw from them, which should hopefully do the same job as the PAC2 but is also packaged into a complete unit with heat sink and cable gland etc.

Hi Diana, if you have any info on the EVR mentioned, maybe you could link to it?

 

Andy.

Paul Reed's picture

Re: Solar Energy Management

Hi Diana, thanks for the posting.

Can you tell me what the linearity of the output is in proportion to the 0 - 5V control voltage?
i.e. 1V = 20% power, 2.5V = 50% power ect.  Do you have a chart of  it's performance please?

Also, is the control input & ground adequately isolated from the high voltage sides, as we would need to share a common ground between the PAC2 and the control module.

Paul

madmurg's picture

Re: Solar Energy Management

Phill W's picture

Re: Solar Energy Management

Right, I'm back.............. I am now the proud owner of an Arduino Uno, a Cyrdom proportional power controller, two CT sensors and an assortment of 'bits'.

So, the cunning plan is:

Use the Arduino to monitor the output from the solar via a CT sensor and monitor the take from the house sockets (the only significant drain during the day) with the other.

Using the Arduino calculate the difference in generated and consumed and divert the excess to the immersion circuit using the crydom by ramping up the analogue out on the Arduino.

I have got my CT sensors from proto-pic (I have to say the service is good!) and working on an input to the arduino using this circuit from MadMurg HELP I need some input - Using the CT interface calculations I think I need a 220 or 240 ohm resistor in series with the CT output to give me full range on the analogue (12 A through the solar - sockets will be more)?

To drive the Crydom, I am using this circuit to give me the full range, I'm using an LM358N rather than an LM324.

I have a nice aluminium case to divert any heat and my Solar installer seemed keen to see the end result and install the mains side of things for me.

Maybe I will start a new thread once I get started, but any input from you more knowledgeable peeps would be good!

Cheers

Phill

Paul Reed's picture

Re: Solar Energy Management

Nice one Phill, look forward to hearing how this progresses.

My unit diverted over 7kWh's of power to the immersion heater today, so its definitely worth the effort as yours will be even more efficient than mine.

 

madmurg's picture

Re: Solar Energy Management

Hope you get on ok phill as above my controller is working great, i have a full tank of hot water by 11 am everyday. I dont think my gas boiler has even fired up this week.

madmurg's picture

Re: Solar Energy Management

Burden resistor calculator
http://tyler.anairo.com/?id=5.3.0

Phill W's picture

Re: Solar Energy Management

Cheers madmurg, used that, tells me I need 272 Ohms, the CT sensor has an inbuilt 10 Ohm resistor and 2000 turns which using the calculator tells me the CT sensors range is 353A, so I would only be getting 1/27th of the range which surely is going to be too small to monitor accurately?

 

edit - 2000 turns not 200

Diana's picture

Re: Solar Energy Management

Hi Paul

I have just had some feedback from our Technical department and this is their response to your question.

  1. The conduction angle output of the phase angle controller with respect to the control signal input is linear, but not the actual RMS voltage. See graph below. The conduction angle on the “x” axis could also be the control signal i.e. 0-180 degrees = 0-5v dc.

  1. Yes, the control input and ground are completely isolated from the high voltage side on both the PAC and the EVR controller. The isolation voltage is at least 2500V rms.

Sorry for the late response and hope this information helps.

Diana

Diana's picture

Re: Solar Energy Management

Hello Andy,

Yes, that day you rang and mentioned you found us on this forum I was viewing these posts. Although I am not technical I can hopefully create some sort of link between the company and people on here.

The only information we have at present is all contained in our datasheet on our website. http://www.united-automation.com/evr-25-phase-angle-power-regulator-stack/ 

If we get any further information or any new products that would help, I will post it on here.

Diana

 

 

calypso_rae's picture

Re: Solar Energy Management

Hi folks,

Like many others, I'm keen to keep the power from our newly fitted PV panels in-house.  There's a lot of interesting material here to read; my apologies if answers have already been given but I've yet to find them.

My objective is simply to divert excess PV power towards our existing 3kW immersion heater for DHW.   I've no wish to monitor/display the overall power consumed on-site; I just want to keep my export rate to a minimum.

Maybe I'm missing something, but it seems only necessary for me to measure the current in one place (the grid supply) rather than calculating the difference between the currents generated and consumed on site.  Won't this approach be more accurate anyway? Having determined the direction of the grid-supply current (by phase-comparison with the voltage), power to the immersion can then be automatically varied so as to obtain a maximum export of some 'safe' value, e.g 200W, or whatever.

I would like my controller to go into a low-power state when the PV system is inactive.  Monitoring the 'active' LED on the inverter's front-panel will hopefully allow this to happen.

Looking forward to doing some programming again.  Now where did I put those C manuals ...

Robin (Merseyside)

 

madmurg's picture

Re: Solar Energy Management

You need to know what spare power you have to play with so you need to measure the power being used by your house minus the power from your pv. This will give you spare power. So if you have 1000w spare power you need to put 1000w to you immersion heater.

calypso_rae's picture

Re: Solar Energy Management

Phill W on Thu, 29/03/2012 - 22:32 wrote:.

"... the cunning plan is:

Use the Arduino to monitor the output from the solar via a CT sensor and monitor the take from the house sockets (the only significant drain during the day) with the other.

Using the Arduino calculate the difference in generated and consumed and divert the excess to the immersion circuit using the crydom by ramping up the analogue out on the Arduino."

Hi Phill,

If, like me, your sole objective is to avoid excess power being wasted, is it necessary to measure power in two places?  If you just measure it at the grid connection, then adjust the Crydom to maintain a small level of export, won't that do the trick?  A V/I phase-measurement is one way to determine the direction of the current, but there may be an easier/better way ...

Our supply meter, a Landis 5235A, has an LED which glows red when we're exporting.  By monitoring that LED using an optical sensor, the sketch can be informed whether the current flow 'at this moment' is being metered (when importing) or not (when exporting).  Regardless of any user measurements, it's what the supply company's meter is measuring that really matters 'cos that's what determines the bills.

Regards to all, Robin

madmurg's picture

Re: Solar Energy Management

But how will you know how much power to put to the immersion heater

calypso_rae's picture

Re: Solar Energy Management

The supply current, which is being continuously monitored, is surely all that matters.  By varying the control signal, the system needs to dynamically 'home in' on the optimal setting so that the measured current is always as intended (e.g.  0.4mA  export).  By this means, small changes in generated power such as variable cloud cover can be readily accommodated without ever slipping into chargeable territory.  But if the LED is ever found to be off, my sketch would immediately kill all power to the immersion heater (pennies being tight in Lancashire too ...)

Once the kettle has boiled, the next current measurement can be used to determine how much power should be sent to the heater.  The relationship between measured export current and the control signal for the heater is all important but this aspect should become more clear once I have a real system to play with. 

On a sunny 2.5kW day, the power to be dumped to the heater will depend greatly on how much the house is otherwise consuming.  Unfortunately, the required control signal is likely to be non-linear.  Two possible approaches to this:

1.  Devise a calibration table so that +/- 100W of extra power can be predicted at each stage of the heater's profile.

2. Allow the system to 'home in' on the desired setting where a known amount of grid current  is being exported.    Providing that the all-important LED never goes off, a smart system should get pretty adept at predicting how much to alter the control signal to achieve the desired change in current.  As Manuel so delightfully put it "I learn, Meesta Fawlty, I learn".

 

 

 

calypso_rae's picture

Re: Solar Energy Management

Sorry, I meant 0.4A (for 100mW of exported power at 240V ac)

With the Open University's email system, the sender can delete emails after sending them.  Perfect for situations like this :)

madmurg's picture

Re: Solar Energy Management

But i still dont understand how you will know how much your pv is producing if you are only using one ct on the ring main. Also what about the other equipment in your house that uses power, like oven hob lights etc

Paul Reed's picture

Re: Solar Energy Management

Could you not....

...build the single channel monitor (using current & voltage measurement), and clip the CT on the meter tail reversed (so it measures exported power instead of imported, you should then know how much is being exported.

As you're not interested in measuring imported power, include something in the sketch like this after the;

if (ch1.realPower < 0)  {
     (ch1.realPower = 0);  }

So the reading will not read below zero (imported power)

But then you need to compensate for the power being consumed by the immersion heater to prevent hysteresis, so lets assume its a fixed 1kW heater for simplicity.

The trigger for switching on the heater could be 1.1kW of exported power, but then the following measurement cycle would read 0.1kW (because 1kW of the 1.1kW is being used by the immersion heater), and so it would switch the heater off.

To compensate for this, the power of the immersion load could be added to the exported measurement similar to;

if (imm_heater= On)  {
   (ch1.realPower = (ch1.realPower+1000);

So now, when the immersion heater is switched on, the trigger for keeping the heater on is still 1.1kW, but the measurement will still be 1.1kW (0.1kW + 1kW) and the heater will remain on.

If a 200W lamp is switched on, the measurement would then read 1kW, ( 0kW + 1kW) and the trigger level of 1.1kW would not be met, and the heater would be switched off. (It would be 0kW because we would not be measuring imported power)

This is all theory of course, but this was the way I intended to initially develop my project until I decided that I would like to see the data too.

Paul

calypso_rae's picture

Re: Solar Energy Management

If all I want to do is to limit my exported power, why do I need to know what my panels are producing? 

On a good day, if the panels are generating 2.5kW and the house is consuming 2kW, I would measure an export flow of 500W.  If I wish to export no more that 100W, my heater would need to consume 400w (or an extra 400W if it's already partially on).  On a poor day, the panels may be generating 700W with the house consuming 200W, so I would still measure the same export flow of 500W.  In both cases, the change in control voltage to increase the heater's consumption by 400W will surely be the same.  But why measure power in two places if one will suffice?

The clever part is to correlate the change in control voltage with the extra power that it causes the heater to consume.  For a resistive load, doubling the voltage will quadruple the power, so there appears to be a non-linear relationship from the outset.  Essentially, we need to establish the relationship between the control voltage as set by the Arduino, and the power consumption of the heater.  This relationship shouldn't change with time so can be hard-coded into the sketch. 

Having determined how much the grid current should be increased/reduced by, I intend to call a function UpdateHeaterSetting() which will calculate how the control voltage should be changed to cause this effect.  This function will need to know two pieces of information: the desired change in grid current, and the existing setting of the heater's control so that the appropriate part of the non-linear profile curve can be used. 

An alternative approach would be for the control logic to simply 'home in' on the desired current level.  This is more or less how our Inverter 'knows' how much current to draw from the panels for optimal power.  With multiple PV panels in series, each with a non-linear profile, and often with uneven shading, the inverter's logic is somewhat complex, as has no doubt been touched on elsewhere in this forum.

 

calypso_rae's picture

Re: Solar Energy Management

Thanks Paul,

I follow your logic for the case of discrete loads that can be switched in or out.  Because they're always operating at full power, they will always consume their stated values.  But like many other users it seems, I would like to have a finer degree of control of the load.  Our PV system is nominally 2.8kW, but our panels face ESE so we lose the sun quite early in the afternoon.  Every watt is precious!

Whichever approach I end up using, the system will need to cope with a 3kW kettle being turned off on a sunny day when there is no other load.  My control system for the heater must not overshoot. 

Robin

Paul Reed's picture

Re: Solar Energy Management

Robin, I chose a 1kW fixed load by way of example, but the 1kW offset could become a variable, that would change depending upon how much power is being provided by percentage;

(ch1.realPower = (ch1.realPower+(Percent_power * 30));

where Percent_power is the percentage of power being delivered to a 3kW immersion heater driven via a Crydom etc.

ie 10% of full power = 300W
(ch1.realPower = (ch1.realPower+300);

Paul

calypso_rae's picture

Re: Solar Energy Management

Paul, I'm not intending to use any kind of calculated offset.  For any load that's non-linear, there will always be an error when predicting the effect of each change (i.e. the change in grid current for a given change in control setting).  But by repeatedly measuring the grid current and adjusting the control setting accordingly, the system should 'home in' to the optimal setting for the prevailing conditions fairly rapidly.  By limiting the rate at which the control setting can change, the system will be damped and therefore shouldn't oscillate wildly. 

Small fluctuations around the target point are fine; this is just the feedback doing its job. Small changes in the available power due to changing cloud cover will be automatically tracked, but step-changes such as a kettle going on are more challenging ... 

Depending on one's outlook, rapid reductations in available power could simply be accommodated by allowing the control logic to adjust for the new conditions.  However, some chargeable grid power would be consumed during this process, and this mode of operation may therefore be against many user's principles.  My preference is to monitor the LED on our supply meter and kill the heater's power immediately if the control system ever strays into chargeable territory.  Experiments with a kettle yesterday showed that the "reverse energy detected" lamp goes out within 1/1000 of a kWh being consumed (hence a max penalty of 0.015p or thereabouts per cuppa)

Must be time for me to start building something.  Can anyone advise me please how frequently current is measured with the standard sketches. TIA

Paul Reed's picture

Re: Solar Energy Management

The offset variable I mention would be set by measuring the load, so I don't see how there would be an error.

The time of each measurement cycle depends upon how many wavelengths you have set emon to sample. In my case I measure 3000 and that takes 4.1 seconds.
This means that as a measurement is taken every 4.1 secs, if the kettle is switched on immediately after a measurement, I would pay a proportion of it's load for 4 seconds until another measurement is taken.
That doesn't cause me any concern as the amount of power concerned is minimal compared to my gains (4 secs @ 3kW = 3.3Wh - and that's the worse case scenario!).

Good luck Robin, keep us updated with your progress.

Paul

 

stuart's picture

Re: Solar Energy Management

I've just had a couple of weeks holiday so missed out on the recent threads, but I am also now the proud owner of a shiny new SSR upon which I'm going to try the burst fire method of control.

 

markbeal2's picture

Re: Solar Energy Management

 

I have built a unit for this.

I have just pasted this from my original post. I would very much appreciate any contribution towards completing a sketch for this.

 

I have built a unit for this. In the unit is a Kemo 4Kw Triac controller http://www.kemo-electronic.de/en/Light-Sound/Effects/Modules/M028N-Power-control-110-240-V-AC-4000-VA.php. Connected to that is a PWM controller http://www.kemo-electronic.de/en/Transformer-Dimmer/Converter/M150-DC-pulse-converter.php.

These in the uk are available from Brocott UK on the web; I have done it this way because these modules are available to anyone who is not to good with electronic circuitry building.

I have split my immersion heater MCB off from the main domestic load in it's own small consumer unit.

Also in the unit is a 30A relay that will operate on and off from a small bank of relays (bought on Ebay) also in the unit. The 30A relay is to completely isolate the Triac control unit when not enough energy is available from the solar.

I have fitted a 9 pin rs232 type connector to the aluminum case it is installed in which carries the PWM signal, 12v for the small relays and signals to operate the small relays and a led to indicate when power is on to the controller.

There is an 9 pin RS232 lead linking the two units so basically, the mains is isolated from the low voltage Arduino based unit. 

This bit all works fine and I would recommend perhaps to do it this way; I will post a pic of the unit next week.

The only thing I cannot get right is the sketch; I have tried using the example voltage and current sketch on here and installed the Emonlib but the sketch just throws up errors when I compile it. I have a 4 line lcd which i have placed into the separate which works fine and should give me all the information I require. Could someone please, please help me with this?

I am mid 50's and some of the sketch I just don't understand, seems harder to take new things in the older you get.

I suppose you could use the arduino based unit to control a storage heater as well as hot water with another power control unit like I mention before. The immersion heater will switch off when it is hot enough via the thermostat so depending on your PV system some spare energy would be available. Monitor the immersion heater as well via a ct.

Mark.

 

 

Paul Reed's picture

Re: Solar Energy Management

Exactly which sketch are you using - please provide link to the sketch.
What version Arduino software environment are you using (to compile the sketch).

Paul

PS being mid 50s shouldn't slow you down.  I was older than that when I first started programming! 

markbeal2's picture

Re: Solar Energy Management

This sketch to start with Paul, errors on compile. Then I tried yours and that threw up errors. I'm using latest version of Arduino software.

 

#include "EmonLib.h"              // Include Emon Library
EnergyMonitor emon1;              // Create an instance
 
void setup()
{  
  Serial.begin(9600);
  
  emon1.voltage(2, 234.26, 1.7);  // Voltage: input pin, calibration, phase_shift
  emon1.current(1, 111.1);        // Current: input pin, calibration.
}
 
void loop()
{
  emon1.calcVI(20,2000);          // Calculate all. No.of wavelengths, time-out
  emon1.serialprint();            // Print out all variables
}
Paul Reed's picture

Re: Solar Energy Management

If you don't provide the information that I requested, then sorry I can't help.

1) Provide a link to the sketch you are using
2) Which version number of Arduino Software are you using?

Paul

markbeal2's picture

Re: Solar Energy Management

link is http://openenergymonitor.org/emon/buildingblocks/arduino-sketch-voltage-and-current

Version is arduino-1.0

I have included the EmonLib into the libraries of Arduino software.

 

 

Paul Reed's picture

Re: Solar Energy Management

My sketch (which is an older version of the openenergymonitor code - not my own work!) was written to compile under version 0022, and has not been modded to work with Arduino 1.0 so you would need to install the older Arduino version 0022 to compile my sketch. If then you still get errors, post what they are, and I'll help if I can.

I have not tried the sketch that you are using so can't advise you other than you are using the correct version of Arduino software for that sketch, and can see no reason why it should not compile as it will have been well tested by the authors before being made public and being placed in Github.

Paul

markbeal2's picture

Re: Solar Energy Management

I'll try the old version but I did try to message Trystan about it but have had no reply from him as yet.

sharmead's picture

Re: Solar Energy Management

I have 3.9Kw PV installed last week & I too am looking for some guidance on how to set up an automatic switched immersion heater controller. I have a 500l storage tank with solar coil and four 3Kw immersion heaters (fitted when I applied for a wind turbine which thankfully was turned down) These four heaters can easily be switched with relays to give seven steps from 750 watts to 3 Kw, This is to my thinking preferable to the Triac route as there is no waste heat and after all where does the solar go when the Triac is off? To the grid I would have thought, which rather defeats the object. I'm looking for something which needs a minimum of of modification, Although I have (had) an electronics background,  at 77 I;m getting a bit past it. Any advice gratefully received.

Robert Wall's picture

Re: Solar Energy Management

"Where does the solar go when the Triac is off?"

That's an interesting point. I think the 'safe' answer is yes, you will be using the grid as an energy store and there will be a current ripple as you export power during part of the cycle and import power over the remainder. The next layer of complication means we have to consider what energy storage the solar inverter has. If there is a filter somewhere that is capable of storing enough energy to supply the phase controlled load when the triac is firing, and it can recover that energy while it is off, then the "ripple" power will be much reduced (though probably not eliminated, because the mains is likely to have a much lower impedance then the inverter output).

I think you will need to speak to the technical department at the inverter manufacturers to ask them how their equipment reacts to that sort of a load.

Whether the 'ripple' power is correctly metered or not could also be a good question. It ought to be, provided your meter does 'unwind' when you are exporting power.

Maybe it's a stupid question, but has a manufacturer (I think it would need to be a manufacturer) considered feeding the d.c. from the solar panels directly into an immersion heater, bypassing the inverter?

 

calypso_rae's picture

Re: Solar Energy Management

"Where does the solar go when the Triac is off?"

That's exactly the point I've been trying to discuss of late, but I didn't put it quite as succinctly. 

My understanding is that electricity meters have a 'window' which allows small amounts of power to flow to and from the grid without being recorded.  My mental picture is of an accumulator of width 0.002kWh which always starts in the middle.  Provided that you remain within this window, nothing is recorded.  If the upper limit is reached, another 0.001kWh of consumed power is recorded and the accumulator is reset.  If the lower limit is reached, the accumulator is again reset but the consumed-power register is unchanged.  My Landis 5235A meter can monitor power in both directions but has not been set up to do so.  As configured by S.Power, it repeatedly flashes 'rEd' which apparently means "reverse power detected".  Something like anti-matter maybe ;)

Being permitted to consume every last watt of power on-site, while being paid the export tarrif for a nominal 50% of all generated power, is probably not the way the system was intended to operate.  But if it saves me from firing up the gas boiler for a bath, it's got to be good for the planet!

I don't think the inverter has any capacity for short term energy storage.  And if the DC were to be used directly, the owner would forego the FIT benefits. 

Robert Wall's picture

Re: Solar Energy Management

"I don't think the inverter has any capacity for short term energy storage."

That is what I would have expected, but I don't know. Though there is probably a degree of filtering on the output to reduce switching noise, I very much doubt that it would be enough to sustain 3kW worth of load for a quarter of a cycle or so. And I rather imagine the manufacturers would react in horror at the thought of large amounts of circulating vars.

"And if the DC were to be used directly, the owner would forego the FIT benefits."

I don't see what the difference is - I didn't mean exclusively feed only the water heaters, I meant extract what power you can at d.c. direct from the panels, and convert and export the surplus to the grid as before. I guess the real answer is; it adds complication.

markbeal2's picture

Re: Solar Energy Management

Thats what I'm working on Robert, Mine like others will feed any surplus into the Immersion heater what ever the level of the PV generation. If the house is using more or equal to what is produced the Immersion heater will stay off until the level goes over the threshold.

markbeal2's picture

Re: Solar Energy Management

Heres some pics of my separate power controller, I had and old cast aluminum case knocking about so used that. I might paint it soon.  It has a 9 pin plug on the side and a bi-pass switch in the other side for full manual power.

The led on the front lights when some energy is going in the immersion heater.

Mr. Sharkey's picture

Re: Solar Energy Management

"Where does the solar go when the Triac is off?"

I'm getting increasingly uncomfortable while thinking of a triac controlled dump load. Not only is the solar power's destination during the off state in question, but it might be worse - much worse.

Consider:

Excess solar production: 1,500 watts
Dump load: 3,000 watts

In order to achieve parity, we need to dump that 1,500 watts into the dump load. Using a triac, we would aim for a phase angle of 50%, meaning the duty cycle would be equal on/off timing.

The problem is that at the top of the 50% duty cycle, the immersion load is actually drawing 3,000 watts. I know that the average power is 1,500, but instantaneously, the power is 3,000. Where is the additional 1,500 watts coming from? The grid!

Not only are you not exporting 1,500 watts half the time, you are purchasing 1,500 watts half the time!

A mechanical utility meter would forgive this, as there are physical ballistics at play, but a modern digital meter would likely bill you for that 1,500 watts. If it averages time, it would look like 750 watts on your bill, but still, you aren't fooling the meter, you are purchasing power to heat the water and "throwing away" half of your power production during the off time.

Do electronic utility meters ignore partial-cycle loads? I'd imagine not, as that would mean that any loads controlled by a thyristor would not be billed to the customer. Utility companies are all about revenue, not charity.

I know for a fact that the utility meter on my home records any solar production that leaks back into the grid as consumption, so I'd be doubly screwed, I'd get billed for the 750 watts (1,500w @ 50%) while the load was on-cycle, then get billed for 750 watts (1,500w @ 50%) while the load was off-cycle. the net result would be that it would look on my bill as if I'd been running 1.5kw exclusively off grid power.

OK, so in the real world, this example is over-simplified, it doesn't take into consideration the phase angle of the current out of the inverter as well as a number of other dynamic AC power variables. If you were to consider the same case study using DC (PV and batteries instead of inverter and grid) and PWM, things would be much more cut-and-dried as far as the theory and suppositions.

It would be possible (fairly simple, really) to set up a revenue-grade utility meter, a lamp dimmer and a load and see what the meter registers as consumption at 50%. This wouldn't answer what the solar is doing during that time, that would probably require a more sophisticated test setup.

At any rate, I think I'm tossing out my plans to try using a triac on my system. I'll stick with the variable transformer, thank you.

Comments?

dave.s's picture

Re: Solar Energy Management

"A mechanical utility meter would forgive this, as there are physical ballistics at play, but a modern digital meter would likely bill you for that 1,500 watts"

I'd think we need some tests. Following the thread at http://www.electriciansforums.co.uk/central-heating-systems/23969-immers... on which pauldreed was commenting, others report that a load that is triac controlled does not register as additional consumption. The metering is generally done over a number of cycles (exact number unknown and probably down to the meter manufacturer).

"I know for a fact that the utility meter on my home records any solar production that leaks back into the grid as consumption, so I'd be doubly screwed, I'd get billed for the 750 watts (1,500w @ 50%) while the load was on-cycle, then get billed for 750 watts (1,500w @ 50%) while the load was off-cycle. the net result would be that it would look on my bill as if I'd been running 1.5kw exclusively off grid power."

That sounds like a very dodgy meter! Any exported power should not register on your supply meter. Old analogue meters would run backwards, so export got subtracted off your consumption, but digital meters should be directional. I know mine is as it actually displays the direction and very coarse indication of power flowing

Whilst you may be tossing out your plans for triac control, my parts are on order (copying markbeal2 with the Kemo 4Kw Triac controller and M150 pulse converter. Found slightly cheaper than Brocott UK on Ebay, currently items 370539618531 and 370539615690 come in at 49EUR from Germany). I'll report back with my results once I've had a chance to get it all running with my 3kW immersion heater. No guarantees that all meters will then work the same, but I would expect there to be some standardisation.

Satman_uk's picture

Re: Solar Energy Management

Not a dodgy meter at all....e.g. the ampy 5235A has a unidirectional mode that can add up power in both directions into the same kwh register, a dodgy mode to be left in by the utility perhaps....

Section 2.4

http://www.solarinverters.com.au/files/users_manuals/usermanual-ahmzqq.pdf

Lloyd's picture

Re: Solar Energy Management

I've resisted the temptation to pitch in on this one, and will probably regret it,  but...

Using a triac to control a (resistive load) is a standard approach.  It is used in millions of lighting circuits.  An immersion is no different,

Your meter does not record KW, it records KWh. ie. energy consumed over time, not peak energy or instantaneous energy.

Think of a light dimmer.  Set to 100%, the light will consume 100%, and your meter will record that.

Set the dimmer to 50%, the light will consume 50% (it will less bright, and generate less heat).  But the other 50% does not heat up the dimmer switch (assuming triac control and not the old resistive type), or go anywhere else.  You have not used the other 50%, so your meter does not record that you have used the other 50%.  You should not look at this on a individual cycle basis.

 

Lloyd

Lloyd's picture

Re: Solar Energy Management

madmurg, can you tell me which Crydom you used in your immersion controller?

Thanks

Lloyd

Mr. Sharkey's picture

Re: Solar Energy Management

"a load that is triac controlled does not register as additional consumption. The metering is generally done over a number of cycles"

I think that you need to understand that the load calculations are ~averaged~ over a number of cycles, not that partial cycle loads are ignored. If partial cycle consumption was not registered, then the utility would be allowing consumers to run dimmable lights free, and I don't think that's going to happen. Note that many heat pumps these days use inverter-controlled circulation fans, think that the power company is running all of those gratis? I don't.

The utility meter on my home is a Itron Centron C1S. Although it's capable of detecting and recording bi-directional power flows, it requires an additional "personality module" and specific programming to do so. As installed, the meter can tell which direction the power is flowing (shows an indicator on the display), but continues to increment the consumption upwards when the solar is going to the grid. This was the whole point of my building a diversion load controller, the utility was charging me to put clean power on their lines.

To be sure I understood how the meter works, I bought a case of them on eBay and ripped them to pieces on the test bench, performing various experiments to satisfy my curiosity. It would be easy enough to dig one out of storage, set it up with a dimmer to power the immersion heater at 50% and read the results on the display. My prediction is that 50% duty cycle will result in the meter registering half the load wattage per hour.

I get to start my learning all over again in a couple of months, as the utility is switching over to "smart" meters with the in-built radio link. No more smart meter reader showing up at my door each month. How the new meter is going to react to solar production is anybodys's guess, but I'd bet that it will be programmed in the default configuration of production=consumption, that's how the utility thinks, "If we can't bill them for it, they must be cheating".

calypso_rae's picture

Re: Solar Energy Management

The Landis 5235A supply meter mentioned earlier measures power in chunks of 1/1000kWh.  As long as the net flow of power in or out is less than 1/1000kWh, nothing is recorded by the meter.  For a 3kW immersion, 1/1000kWh of power is consumed approx every second.  

A phase-angle controller operates on a timescale, around 100 times faster than this.  During the first (off) part of the cycle, a small amount of PV-generated energy slips away into the grid; the same amount of energy then returns during the latter (on) part.  The low-impedance grid  is providing a short term buffer facility, for which no charge is made.

Think of a gymnast who needs a trampoline to clear a vaulting horse.  Although the only source of power is coming from the gymnast, the trampoline allows energy to be accumulated over a longer period than would the floor alone.  The low-impedance grid is our trampoline.

 

madmurg's picture

Re: Solar Energy Management

Mr. Sharkey's picture

Re: Solar Energy Management

"As long as the net flow of power in or out is less than 1/1000kWh, nothing is recorded by the meter."

So what you are saying first is that the meter ignores power levels under 1 watt. I suppose that I could find this acceptable. What I don't see is how you relate the timing of the power as determined by the phase angle as being below the 1 watt threshold. When the duty cycle is 50% (for example), the instantaneous power level is 3kw, the meter is not going to ignore this. It will register it as a 3kw load and time-average the power level according to the portion of the cycle (or cycles, if averaging over multiple cycles), and integrate the power into a reading for which you'll be charged when the utility bill is due.

You supposition about using the grid as a short-term storage system would be correct for an analog, disc-type meter, or a digital meter that can count up and down with forward/reverse power flows, but for every meter I'm familiar with, this would result in your accumulating kWh that would be billable at the end of the month. Every digital meter that is set up for consumer power production measurement will have two registers, one for consumption, and another for production. This way, the utility can keep track of how much you are consuming at one rate, and how much you are backfeeding the grid, perhaps at a different rate. If they are kind enough to offer "net metering" (consumption and production valued at the same rate) then the numbers are summed at the end of the month as you are billed the difference.

To further settle this question, I've set up a digital meter in a test setup and will accumulate some data this afternoon to show that the meter works as I propose.

logic's picture

Re: Solar Energy Management

I'm currently using a 2 - 10v Crydom 10pcv2425 proportional control for my solar to immersion heater setup and as my meter displays a green LED when power is flowing back to the grid then I know that all is working as it should l am still generating and not buying power.

My setup uses the emontx/GLCD/Nanode setup with an extra emontx board to wirelessly control the immersion.  I did have to increase the power reading emontx's transmission rates, and I 'borrowed' madmurgs idea for the 10v circuit (thanks).  Also I added a third CT to measure the immersion heater power so I wasn't relying on a calculated power from CT power 1 and  2. I do all the power measuring from the meter cupboard and have the 2nd emontx board dedicated to the PWM/Crydom controller.

As said above, I can watch the green LED stay lit while diverting from as close as 50 to 100Watt of spare power to my immersion.  The only downside I have found so far is that due to only currently having 100 CT transmissions per minute when the kettle is switched on I see the green LED go out, but only for about 1 second until the PWM is adjusted and immersion power decreased. The setup handles normal household useage changes or cloud cover with no problems - I guess worst case adding a maximum of about 1 or 2 pence per day which is more than offset by my 'expected' decrease in oil consumption.

Edit - I couldn't get into the link madmurg posted before writing this, but now I see it is exactly the same Cydom controller.

 

Dennis

Paul Reed's picture

Re: Solar Energy Management

Mr Sharkey, I think you are missing the point which Calypso rae is making. It's important to understand what he means by 'chunks', because the meter simply does not ignore power usage of less than 1Wh, it totals all usage up no matter how small, deducts any export power, and when 1Wh of power has been recorded, it then passes the 1Wh to a separate register within the meter which counts total usage (accumulator).
It could take 1 second to build up1Wh or it could take 5 minutes, and most meters have a flashing LED indication, 1 flash = 1Wh.

When you set up your rig - count the flashes.

calypso_rae's picture

Re: Solar Energy Management

pauldreed: It's important to understand what he means by 'chunks', because the meter simply does not ignore power usage of less than 1Wh, it totals all usage up no matter how small, deducts any export power, and when 1Wh of power has been recorded, it then passes the 1Wh to a separate register within the meter which counts total usage (accumulator).
It could take 1 second to build up1Wh or it could take 5 minutes, and most meters have a flashing LED indication, 1 flash = 1Wh

Yep, I'm happy with that explanation, except that for "power", I would prefer to write "energy" :)

Robert Wall's picture

Re: Solar Energy Management

From the meter manuals that I've read, they do indeed have a lower threshold below which the power is considered to be zero. It's referred to as "starting current", "anti-creep" or something like that. For the Ampy 6535 linked higher up this thread, it is:

Current (Base) Direct connection  Ib   5A, 10A, or 20A
Current (Max) Imax                                  40A, 60A, 80A or 100A
Starting Current (IEC)                             0.4% of Ib
Max measuring range                            20mA up to 100A

 

and for an ABB 3-phase ODIN meter, the manual states:

Min current Imin:                                    0.25 A for direct connected meter, 0.10 A for transformer connected meter
Min current inside class Itr:                  0.5 A
Reference alt. Base current Iref (Ib):  5 A
Maximum current Imax:                        65 A for direct connected meter, 10 A for transformer connected meter
Starting current Ist:                                20 mA

 

Mr. Sharkey's picture

Re: Solar Energy Management

OK, so maybe I'm getting distracted by the premise that his particular meter might be capable of see-sawing some energy back and forth without registering it as consumption. If it counts up to .9 Wh during dump load operation, then it counts down 1.8 Wh during inverter feed to the grid, etc, etc, then it never passes the 1 Wh threshold to pass the "chunk" over to the register to increment the total displayed and billed.

The whole premise hinges on each individual cycle having less than 1 Wh of energy contained in it, in either direction, *and* the meter doing a proper increment/decrement with each cycle. I'm not going to try to do the math, much less try to calculate the phase angle-vs-dump load wattage limit for 1 Wh/cycle.

Now I wish I hadn't wasted four hours of my day messing with digital utility meters instead of washing the living room walls to prepare for painting.

Mr. Sharkey's picture

Re: Solar Energy Management

Isn't that interesting?

Since I felt like I had wasted half the day, and because the utility meters were still on the bench before I put them back into storage, I decided to test out the "chunk" theory.

Load = 100 watts @ 120 volts (causes 1 Wh to pass each 36 seconds).

Wired the meter so I could connect the load in phase and out of phase alternately with clip leads.

Ran the load for 36 seconds to verify indication.

Ran the load another 30 seconds, disconnected.

Reversed the current loop though the meter so it looked like the load was producing instead of consuming.

Ran the load for 60 seconds.

Reversed.

Repeat above 8 times.

Result = the 1 Wh indicator did not illuminate, showing that the meter was incrementing, then decrementing the accumulated Wh back and forth without sending it to the register.

It works! I'm confounded, amazed, and apologetic all at once.

Oh, and it turns out the maths weren't so gnarly after all:

1000 = watts load
3600 = seconds in a hour
120 = half cycles in a second (60 Hz, N. American standard)

(1000/3600)/120 = 0.023 Wh per half cycle

At 3 Kw load = 0.069 Wh/½ cycle

For those of you in the rest of the civilised world (50 Hz):

(1000/3600)/100 = 0.0027 Wh/½ cycle

3 Kw = 0.0083 Wh/½ cycle

[edited to correct bad math]

Paul Reed's picture

Re: Solar Energy Management

"....Now I wish I hadn't wasted four hours of my day messing with digital utility meters instead of washing the living room walls to prepare for painting."

Although playing with the digital meters does sound the better option to me!

Lloyd's picture

Re: Solar Energy Management

HI Dennis

How are you powering your second tx - wth a usb psu, or are you using the same power supply as you use to drive the crydom?  Are you measuring voltage at either of your tx?

If you have a schematic, would be really good if you could post it.

Thanks

Lloyd

calypso_rae's picture

Re: Solar Energy Management

Result = the 1 Wh indictor did not illuminate, showing that the meter was incrementing, then decrementing the accumulated Wh back and forth without sending it to the register.

Great, that's just how my meter behaves.  With 1kW of surplus power from the PV, I repeatedly switched our 3kW kettle on for around 0.5s, then off for around 1.5s. While this sequence was maintained, no flicks were seen at the meter's LED, yet the kettle was clearly heating up. 

For some reason, our kettle's heating element did not survive this treatment.  I'm hoping that a proper AC-controller will not have the same effect on its replacement!

calypso_rae's picture

Re: Solar Energy Management

For those of you in the rest of the civilised world (50 Hz):

(3600/1000)/100 = 0.036 Wh/½ cycle

3 Kw = 0.108 Wh/½ cycle

Wow, so your meter flashes 10 times per second for a 3kW load!!!  Thankfully, I get different numbers:

My 3kW load consumes 3000 Wh of energy per 3600 seconds, so that's 1 Wh per 1.2 seconds.  This is the 'flash rate' that I noted while destroying my kettle ...

Mr. Sharkey's picture

Re: Solar Energy Management

"Wow, so your meter flashes 10 times per second for a 3kW load"

No, but I think I see where I made that error (I did mention that I didn't want to try and figure out the math). The time/Watts should have been the other way 'round:

(3000/3600)/120 = .0069 Wh/½ cycle (60 Hz)
(3000/3600)/100 = .0083 Wh/½ cycle (50 Hz)

Proofing:

1Wh/(.0069 * 120) = 1.2077 sec.

Happy now?

No kettles were destroyed in the making of these calculations.

logic's picture

Re: Solar Energy Management

Lloyd

All measurements including voltage are done on the 1st emontx in the meter cupboard, and I just have this sending the power 1, 2 & 3 value's (+ others) at about 100 per minute.  The setup is the solar kit bought from the openenergymonitor shop and a third ct.

The 2nd emontx which controls the PWM/Crydom is powered by a 12v CCTV psu going to this - http://www.ebay.co.uk/itm/260992217237?ssPageName=STRK:MEWNX:IT&_trksid=... This supplies both the required 12v and 5v.  I originally got the 2nd emontx with thoughts of measuring temperatures locally and as it comes complete with wireless and all the connections.  But I've left it dedicated just for the PWM control.

The 10v control schematic is as Madmurg's, and I can certainly upload my programming once I figure out how to - I've just left home to work for a few weeks so the computers are restricted with installing github, but I'll try to figure something (maybe upload a zip).  Is it better to start a new post rather than continue on this one?

Today I can see online that my water tank is all nice and toasty (temp sensors fitted) and all for free!  With oil costing me 68p/litre it should speed the solar payback time as I just missed out on the higher FIT and am on 21ppu.

Dennis

calypso_rae's picture

Re: Solar Energy Management

Happy now?

Yep, I sure am :)

Paul Reed's picture

Re: Solar Energy Management

Now we have a better understanding of how the meters actually record energy, has anyone given any thought to using Thyristor control in burst mode?

I was thinking upon the lines of using Arduino code to switch a Thyristor on and and off via a opto-isolator??
So if we worked on a cycle of every 1 second, the Arduino could switch on the Thyristor for 500ms (and off for 500ms) for 50% energy, on for 250ms (off for 750ms) for 25% power, and so on.

Because the Thyristor would only be switching at zero crossing, it would create less heat and transients, be more accurate in controlling power and would be much cheaper than a Crydom (£1.73p for a 16A isolated Triac, £0.99p for a Triac opto-isolator - Ebay).

What do you think?

Paul

markbeal2's picture

Re: Solar Energy Management

Trouble with Thyristors Paul is that they can latch on. Years ago lightning hit one of our bigger substations and latched the battery charger thyristors full power of 230v output onto a 110v battery bank. The batteries were boiled dry and red hot.

I suggested an over volts relay on the output that switch the input off hence resetting the charger.

Paul Reed's picture

Re: Solar Energy Management

Thanks Mark, but isn't the worst case scenario if the Thyristor latched on, be that I used grid energy to heat the water until it reached temperature and the immersion thermostat switched it off? 

Paul

markbeal2's picture

Re: Solar Energy Management

Well the thermostat switching off is ok but that won't kill the supply. The thyristor would be still switched on to full conductance and still apply full power to the immersion heater until the supply to the thyristor is cut, as in reset.

Robert Wall's picture

Re: Solar Energy Management

The difference between the immersion heater with the thermostat and the battery charger is the thermostat will break the circuit, then so long as the current falls to zero, there's no way the thyristor will latch. Presumably current was maintained in the battery charger and that is why the thyristor didn't turn off.

I'm trying to remember what was done for the very early phase controlled  thyristor d.c. drives. Because thyristors were so expensive, a diode rectifier bridge was used with the (only one!) thyristor in the d.c. side, so it was particularly difficult to turn it off because the current fell below the holding current for only a very brief period. Some research into early thyristor application notes might provide the answer.

stuart's picture

Re: Solar Energy Management

Paul, I'm currently doing exactly this, although using a zero crossing SSR just to save me messing to much with mains electric too much.  Zero crossing SSR's are very cheap and easy to use.

 

logic's picture

Re: Solar Energy Management

Stuart

Would you mind telling us what zero cross SSR you ended up getting?  Also how you are finding it with regards to not buying power etc.?

I went for the proportional control but I'm finding it quite noisy, even with filtering.  At about 40 - 60% I can even hear 'slight' buzzing in my meter cupboard which is located in a different room.  Without the filter it was bad.  If the zero cross SSR setup works out well I may consider changing to this.

Paul Reed's picture

Re: Solar Energy Management

Stuart, can you post your circuit & sketch please?

stuart's picture

Re: Solar Energy Management

Yes I will post it all, its not finished yet, still in the development stages, last night finished wiring up the 240v side to a mains power strip to begin testing !

I'm going to try randomly switching on the SSR using PWM - completely ignoring the zero crossing from my code/timing. Obviously I might switch the SSR on and off before its actually fired, but I'm going to wait and see what happens.

This is sort of burst control without using a random fire SSR.

The difference I'm going to try though is using a current clamp/transformer on the output side to actually measure the power I'm putting into the load so I can increase/decrease the PWM timing to balance the load as needed.  Additionally I can also use this to measure the actual kWh electric delivered to the water heater.

I doubt this method is going to give a perfect balance of power delivered to the load (hot water heater) but time will tell !

 

I'm going down this route as nobody else appears to have done it this way (there may be a good reason!!), and additionally if people want to copy this solution, I'd like to keep the 240v mains electrics to a minimum.  This current method only uses 240v on the SSR, everything else is low voltage DC.

 

Robert Wall's picture

Re: Solar Energy Management

"(there may be a good reason!!)"

That reason might be flicker (small voltage fluctuations on the supply). It is certainly something to be aware of.

stuart's picture

Re: Solar Energy Management

Driving a 35W light bulb using a standard zero crossing relay (using PWM) and a CT loop (wired up as per emonTx)

Seeing as I'm totally ignoring the fact of working out when zero crossing actually is, the table below shows the results...

Its surprisingly better than I expected, it won't be linear because I'm ignoring the zero cross point, so sometimes you may step up the PWM and the power output actually goes down!  This is why I wanted to use the CT loop so I can create a feedback loop to correct as needed.

I'm stepping the PWM up 32 points at a time and then taking 20 readings off the CT and giving an average output - removing the zero power bias of 5W as per below..

You can see when I stepped up from 544 to 576, the power actually went down - I believe this to be purely due to timing issues.

Measuring max power=35W  Measuring zero power=5W
PWM value=0                          Power=0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0; 0;  =  0.00W (0.00%)
PWM value=32     Power=12; 12; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11; 11;  = 11.10W (31.71%)
PWM value=64     Power=11; 13; 14; 14; 14; 14; 14; 15; 14; 14; 14; 14; 14; 14; 14; 14; 14; 15; 14; 15;  = 13.95W (39.86%)
PWM value=96       Power=15; 15; 14; 12; 12; 12; 12; 11; 11; 11; 11; 11; 11; 1; 1; 12; 11; 11; 11; 11;  = 10.80W (30.86%)
PWM value=128    Power=12; 13; 13; 14; 14; 14; 14; 14; 14; 14; 14; 14; 14; 13; 13; 13; 13; 13; 11; 11;  = 13.25W (37.86%)
PWM value=160    Power=11; 10; 10; 10; 10; 10; 10; 10; 13; 15; 15; 16; 17; 17; 17; 18; 17; 17; 17; 17;  = 13.85W (39.57%)
PWM value=192    Power=18; 18; 18; 18; 18; 17; 17; 17; 16; 16; 16; 16; 15; 14; 14; 14; 14; 14; 14; 14;  = 15.90W (45.43%)
PWM value=224    Power=14; 14; 14; 14; 14; 14; 14; 14; 19; 20; 20; 20; 20; 20; 20; 20; 20; 18; 18; 18;  = 17.25W (49.29%)
PWM value=256    Power=21; 21; 21; 19; 18; 18; 17; 16; 16; 16; 15; 14; 14; 14; 14; 14; 14; 14; 14; 14;  = 16.20W (46.29%)
PWM value=288    Power=16; 17; 18; 18; 19; 19; 20; 20; 20; 20; 21; 21; 21; 21; 21; 21; 21; 21; 21; 21;  = 19.85W (56.71%)
PWM value=320    Power=21; 21; 20; 20; 20; 20; 20; 19; 19; 18; 18; 18; 17; 17; 17; 17; 17; 19; 19; 19;  = 18.80W (53.71%)
PWM value=352    Power=20; 20; 20; 20; 20; 21; 21; 22; 22; 20; 20; 20; 21; 21; 21; 21; 21; 21; 21; 21;  = 20.70W (59.14%)
PWM value=384    Power=21; 21; 21; 21; 21; 21; 21; 21; 20; 20; 20; 20; 20; 19; 19; 19; 19; 19; 18; 18;  = 19.95W (57.00%)
PWM value=416    Power=18; 18; 18; 18; 18; 18; 18; 19; 19; 19; 19; 19; 20; 21; 21; 21; 21; 23; 24; 24;  = 19.80W (56.57%)
PWM value=448    Power=25; 25; 25; 25; 25; 24; 23; 23; 23; 23; 23; 23; 22; 22; 22; 22; 22; 22; 21; 21;  = 23.05W (65.86%)
PWM value=480    Power=21; 22; 21; 21; 21; 21; 21; 21; 21; 21; 20; 21; 20; 21; 21; 22; 22; 22; 22; 23;  = 21.25W (60.71%)
PWM value=512    Power=23; 23; 23; 24; 24; 24; 24; 24; 24; 24; 26; 26; 26; 26; 26; 26; 26; 25; 25; 25;  = 24.70W (70.57%)
PWM value=544    Power=25; 25; 24; 25; 24; 24; 24; 23; 23; 23; 23; 23; 23; 23; 23; 22; 22; 22; 22; 23;  = 23.30W (66.57%)
PWM value=576    Power=23; 23; 22; 23; 23; 23; 22; 22; 22; 22; 22; 22; 22; 22; 22; 22; 23; 21; 21; 22;  = 22.20W (63.43%)
PWM value=608    Power=24; 24; 23; 23; 25; 26; 26; 26; 26; 26; 26; 26; 26; 26; 26; 26; 27; 27; 27; 27;  = 25.65W (73.29%)
PWM value=640    Power=27; 27; 26; 27; 26; 26; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27;  = 26.85W (76.71%)
PWM value=672    Power=26; 27; 26; 26; 26; 26; 26; 24; 23; 23; 23; 23; 23; 23; 23; 23; 23; 23; 22; 22;  = 24.05W (68.71%)
PWM value=704    Power=25; 25; 25; 25; 25; 25; 25; 26; 25; 25; 26; 26; 26; 26; 26; 26; 26; 26; 26; 26;  = 25.55W (73.00%)
PWM value=736    Power=26; 26; 28; 28; 28; 28; 28; 28; 27; 27; 28; 28; 28; 28; 28; 28; 27; 27; 27; 27;  = 27.50W (78.57%)
PWM value=768    Power=27; 27; 28; 27; 27; 28; 27; 27; 27; 27; 29; 29; 29; 29; 29; 29; 29; 29; 29; 29;  = 28.10W (80.29%)
PWM value=800    Power=28; 28; 28; 28; 28; 28; 28; 28; 28; 28; 28; 28; 28; 25; 25; 25; 25; 25; 26; 27;  = 27.10W (77.43%)
PWM value=832    Power=27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27; 27;  = 27.00W (77.14%)
PWM value=864    Power=27; 29; 29; 29; 29; 29; 29; 28; 29; 29; 29; 29; 29; 29; 29; 28; 28; 28; 28; 28;  = 28.60W (81.71%)
PWM value=896    Power=29; 28; 28; 28; 28; 28; 28; 29; 29; 30; 29; 30; 30; 30; 30; 29; 30; 30; 30; 29;  = 29.10W (83.14%)
PWM value=928    Power=29; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 29; 29; 30; 30; 30; 31; 31; 31;  = 30.00W (85.71%)
PWM value=960    Power=31; 31; 31; 31; 31; 30; 29; 29; 29; 30; 29; 29; 29; 29; 29; 29; 29; 29; 29; 29;  = 29.60W (84.57%)
PWM value=992    Power=29; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30; 30;  = 29.95W (85.57%)

 

Paul Reed's picture

Re: Solar Energy Management

What 'zero crossing relay' are you using, and how are you triggering it?
The PWM signal is about 490Hz, which equates to a cycle roughly every 2mS, I didn't think a Thyristor could recover in that short time, if fed directly via the PWM frequency without a DC smoothing interface  ...or am I misunderstanding your idea?

stuart's picture

Re: Solar Energy Management

I'm using a very cheap zero cross SSR relay off ebay, cost less than £7.

The PWM signal is too fast at the moment, I didn't worry too much last night on the timing of it, just a proof of concept really.

I'll try again tonight with a slower freqency and also a higher load - good thing I don't have epilepsy as my flashing table lamp was going some last night!

It seems that I'm short of resistive loads to try - got a 1500W wallpaper steam stripper I'll try tonight !!

I've not looked into any thyristor recovery times or DC smoothing, just fired the SSR directly off a arduino PWM pin @ 5v.

I assume that the maximum frequency is twice the mains frequency, i.e. 100Hz as the zero cross happens twice per 50hz AC cycle ?

 

 

Anyone know of a cheap 13-16amp AC current transformer/sensor instead of using the 100A unit I'm using now ?

logic's picture

Re: Solar Energy Management

Stuart

For testing my SSR setup I rigged up a 240V 13A plug & socket, then heated my 3kW kettle several times - mimicking my immersion heater load.  I was shocked at how quickly it boiled even at small power being applied.  I had a 60W lamp in parallel so I could get a visual indication of what was happening.

stuart's picture

Re: Solar Energy Management

Yes I'll try that, only so much water you can boil though, better get the tea out !!

calypso_rae's picture

Re: Solar Energy Management

I'm using this 30A current clamp for £6.99. 

http://www.coolcomponents.co.uk/catalog/invasive-current-sensor-p-677.html

Seems to be working nicely

stuart's picture

Re: Solar Energy Management

Okay, last night I wired up my SSR to the kettle, it turns out I have a 3.3Kw kettle.

I tried several attempts at switching the SSR at lower frequency ranges from 10Hz to 250Hz, generally lower ranges worked better.

I found:

1. At very low frequency (10-20hz) the SSR "skips" out of sync with the mains causing a long period of "off" time, so you see several pulses and then nothing for a second or two (because the SSR is switched on/off before its zero cross on the AC)

2. Because I'm deliberately not looking for a zero cross, the power measurements vary by around 10-20% so it would be quite difficult to keep in a sensible range

3. I found it difficult  to drive the SSR to operate at less than 300W power output through the PWM

 

What this means is that the method I'm currently using does work okay, but I would have to give a large margin between the requested power output and what is actually asked for, and additionally, this method would probably be poor for low power requests.

For instance, if I'm generating 1000W excess solar, I could probably only request 600-700W through the SSR to keep it reliably under this 1000W limit without the risk of an import occuring, because the measured values occasionally (twice per minute for instance) report much higher (900-1200W for this example).

I'm going to try a frequency modulation tonight rather than PWM and see how that favours, additionally I proved that I can measure using the CT clamp when the SSR switches on (hence crosses AC zero) so that may aid timing.

I successfully put a fairly consistant 700W into the kettle for approx 30 minutes and made it boil !

Also found out that I probably need to include the heat sink when pushing 3kW thorugh the SSR (its a 25A model) as it got fairly warm (still cool enough to touch/pick up) after 30 minutes or so.

 

Good fun so far though !

calypso_rae's picture

Re: Solar Energy Management

Modulating the switching frequency sounds an excellent idea to me Stuart.  A 3kW load could be left on for, say, half a second, and then turned off for as long as is necessary to restore the equilibrium.  This approach may also improve the resolution at low levels of surplus power. 

I'm only intending to measure power at the supply meter.  By that means, with suitable damping, the control system should be able to home-in on the best value.  In stable conditions, edge effects in one control cycle will hopefully be compensated for in the next one without straying outside the 'no charge' zone.  It feels rather like riding a bicycle along a straight line.  There's always a bit of wobble from side to side, but as long as you stay on the white bit the job's a good'n!

calypso_rae's picture

Re: Solar Energy Management

A 3kW load could be left on for, say, half a second, and then turned off for as long as is necessary to restore the equilibrium.

On second thoughts, this approach could lead to horrible oscillations.  Each loop of the control logic needs to be able to influence the system's performance during the next monitoring cycle.  It may be therefore be best to keep the switching and monitor cycles in alignment.   One or two Hertz may be about right.

In its Mode 2, the Carlo Gavazzi controller RS:708-2080 can distribute whole a.c. cycles during its 64-cycle control window.  They're not all bunched up at the beginning.  By this means, I feel sure that the net power flow will be better contained within the 1Wh energy window of the supply meter.   But at £61 + VAT, this beast is more pricey than a triac or SSR.

Paul Reed's picture

Re: Solar Energy Management

I have further explored using an Arduino to control the burst firing rate of a Triac as I described above on 26th April.

I've now bought a opto-isolator & 16A Triac, 3 resistors & a capacitor from Maplins, total price less than £5 and made version 1 which is very rough & ready!

The test software is here http://pastebin.com/drFQYFzU  and a video of it is http://www.youtube.com/watch?v=kkgqzkbbCns

As can be seen, I am changing a variable in the Arduino via the serial UART, to change the on/off relationship as a percentage between 10% & 90%, over a 1 second cycle, and the Triac outputs accordingly. My thoughts are that instead of manually changing the variable, it could easily be done via the energy monitor calculations.
The next stage (when I get some time) is to test it with a 3kW load, and see what impact it has on the leccy meter!

Calypso_rae, in my case it should not oscillate as I wired a separate circuit to feed the immersion heater which does not register via the energy monitor.

Any thoughts would be appreciated.

 

Paul

calypso_rae's picture

Re: Solar Energy Management

For the current clamp that I mentioned recently, the datasheet shows that there are two versions: with and without burden resistors.  Apart from the 100A variant, they are all shown as having internal burden resistors so it seemed likely that the one I'm using does too.  But just to be check, I decided to remove the 39R burden to see what happens ...

My background readings immediately shot to 15900W.  Thankfully, when I replaced said resistor, they returned to 20W as before.  Cheers, Paul, for the reminder about fitting protection diodes to the analogue input!

My clamp is labelled SCT-103-030   1202-1003Q  www.yhdc.com

According to the datasheet, this is the 30A version which contains an integral burden resistor.  My findings, however, would suggest otherwise.  The Beijing website makes no sense to me.  Anyway, the component is providing me with good readings, and so far appears to be idiot proof ...

Mr. Sharkey's picture

Re: Solar Energy Management

Beware of unloading a current transformer by removing the burden resistor. ~Very~ high voltages can be induced, enough to damage attached equipment and cause electric shock hazards.

calypso_rae's picture

Re: Solar Energy Management

Beware of unloading a current transformer by removing the burden resistor.

But if the datasheet says that a burden resistor is built in, you would not expect to have to provide one in the first place!

The secondary coil of the clamp that I'm using has a dc resistance of around 38 ohms.  This is presumably because it contains a long length of very thin wire.  Equivalent measurements for similar components may shed more light on this topic ...

calypso_rae's picture

Re: Solar Energy Management

Calypso_rae, in my case it should not oscillate as I wired a separate circuit to feed the immersion heater which does not register via the energy monitor.

Sorry Paul, I don't get the point you're making.  If a 3kW resistive load is to consume only 1kW, it needs to be supplied with power on a 1:2 duty cycle (or maybe 1:3 to give some margin for safety).  Within the limitations already discussed, energy can then be bounced back and forth between the grid and the load via the supply meter without the user being charged.  To provide some feedback for the control mechanism, this 'lumpy' a.c. flow will need to be measured somewhere.  To avoid the system oscillating, these measurements need to give stable results.

Using the conventional emon setup as I understand it to be, a.c. current is normally measured at two points.  While a pulse-fed immersion is active, one of these measurements will always be 'clean' and one will be 'lumpy'.  Which one is which depends on where the water-heater is connected.  In most configurations, I would expect the PV generation measurement to be clean and the consumption measurement lumpy.  In your case, your 'all other household consumption' will be stable but your PV measurement will be lumpy because of the current that's bouncing back and forth between your immersion and the grid.  Another complication of your setup is that current can flow both ways through your PV measurement point.  In most cases, current can only flow in one direction at each point of measurement, so there's no need to measure voltage.

Because we measure instantaneous power many times each a.c. cycle, lumpy flow per se is not a problem.  Getting the timing right, however, will be all important.  That's why I think that power measurements should be taken over the same duration as the on/off control window for the load, probably around 1 or 2 Hz. 

If the immersion's power goes on for 200mS and then off for 400mS, it can be reliably measured as having a 33% duty cycle regardless of where the measurement is started.  But only if the measurement window is 600mS, or multiples thereof.

Robert Wall's picture

Re: Solar Energy Management

YHDC Internal Burden:

It is fairly easy to non-destructively dismantle the Yhdc CT to verify what is inside. Open up the core, and each side of the ferrite core (the limb away from the hinge) are two retaining lugs that hold the bobbin down. Push the core in towards the hinge, and with a bit of a wiggle whilst pushing up on the cable, and the core, bobbin and a small pcb should appear. If that doesn't work, gently prise the retaining lugs away with a suitable tool (I used fine snipe-nosed pliers to get both whilst reaching over the core).

Can you let me know what you find?

Paul Reed's picture

Re: Solar Energy Management

Calypso_rae, let me run over the basic layout;
The emon monitor system has 2 monitoring points, the first is the Solar Feed which constantly  measures the amount of energy developed via the solar array. The second is the Home Feed which constantly measures the amount of energy being consumed within the home.
The immersion heater is fed via a separate feed from the meter, so any consumption made by the immersion heater is recorded by the supply meter, but not by the emon monitor.

The unused energy is calculated by subtracting Home Energy from Solar Feed, and this figure would be used to determine the burst ratio.

I do not see the need to measure the power diverted to the immersion heater as it would not influence the process described above. For example, if I have 1.5kW unused power and the burst ratio is set at 50% over a 1 second cycle (500mS on & 500mS off), then I've achieved my aims. If then someone switches on a 500W household appliance, emon will record 1kW spare, and the burst ratio would be reduced to 33%.
If I wanted to know how much power was diverted to the immersion heater, it can easily be recorded via the software, as we know the full power consumption of the element (3kW), and we also know the periods for which the element is activated. So a little software calculation can determine this information, possibly with more accuracy than using a current transformer monitor. If you view my Pachube page - https://pachube.com/feeds/34843 and look at 'Heater Power' & 'Accum Heater Power', you will see that code doing the calculations for me, it's simply adding up the 'on' time and a little maths to determine the result.

The setting of the burst ratio is always going to be about 2 seconds behind the emon measurements, because emon needs time to do the calculations, but I think that I can accept that delay.

calypso_rae's picture

Re: Solar Energy Management

Can you let me know what you find?

I've bought two of these clamps but so far only used one.  They both look the same inside, each having two resistors in series across the coil.  These appear to be 62R and 10R. 

The soldering looks a bit grim.  I'm tempted to remove these components altogether and rely on a burden of my own that I can trust (including protection diodes!)

calypso_rae's picture

Re: Solar Energy Management

Hi Paul,

As neither of us seems able to follow the other's argument, hopefully someone else will be able to shed more light on this topic.  Maybe we're both right but I can't see how. 

On a more positive note, I regard your flashing light video as superb.  It has finally convinced me that, without resorting to expensive controllers, an Arduino really can control a 240V load, with zero-crossing sensitivity.  I feel sure that this is the best way forward in the long-term.

 

stuart's picture

Re: Solar Energy Management

Nice work Paul, I've spent the last two evenings playing with the SSR and have reached similar results to you.

I've gone down the route of using a arduino PWM timer/interrupt instead.

 

Notice that you're using a 1second cycle time, from various sources, the commercial burst first SSR cycle times seem to use a shorter cycle, 250ms on a lot of them.

I wonder if this avoid's the electric meter registering the power ?

 

I wanted to measure the current in the circuit as well but have struggled to do this and also fire the SSR at the same time on the arduino.

 

Does anyone know of a way to reduce the hardware PWM timers to a lower freqency, the lowest I can get at the moment is about 150Hz - really need 3 or 4Hz !

 

stuart's picture

Re: Solar Energy Management

Paul, forgot to mention, currently we are both firing SSR/Triacs using a "fixed" time window (1 second for instance)

so for 20% power, the SSR is switched on for 200ms and off for 800ms.

I'm wondering if the ON pulses should be spaced across the 1 second, period, so its on for 50ms, off for 200ms, on for 50ms off for 200ms and so on over the 1 second window - wonder if this works better with the electric meters?

Only problem I can see (for me using an SSR) is switching at this higher frequency is the time drift over the AC cycle so you may switch the SSR/Triac on and then off, but in reality the zero crossing has not happened.

Just a few thoughts anyway!!

I found this fairly useful description on page 10 onwards...

http://www.scribd.com/nealmalm/d/51105918-SCR-power-control-Watlow

calypso_rae's picture

Re: Solar Energy Management

Does anyone know of a way to reduce the hardware PWM timers to a lower freqency, the lowest I can get at the moment is about 150Hz - really need 3 or 4Hz !

Rather than using the built-in PWM feature, could you add some code in loop() which calls millis() and then decides whether the output pin should be hi or lo?  This would slow down the measurement frequency slightly but would greatly improve the flexibility of the control scheme.

I'm wondering if the ON pulses should be spaced across the 1 second, period, so its on for 50ms, off for 200ms, on for 50ms off for 200ms and so on over the 1 second window - wonder if this works better with the electric meters?

Yes, I'm sure that would be a great improvement.  Distributing the power pulses evenly throughout the time window should greatly improve one's chances of not getting caught out by the watchful meter.  A longer measurement window could then be employed which would improve the system's resolution.

stuart's picture

Re: Solar Energy Management

The only reason I was trying to stick to the hardware PWM was purely to allow me to then use the CT sensor measuring code to monitor the energy put into the hot water, but I suppose I don't really need to know that as I'm putting power into a known load size.

 

Paul Reed's picture

Re: Solar Energy Management

'Rather than using the built-in PWM feature, could you add some code in loop() which calls millis() and then decides whether the output pin should be hi or lo?  This would slow down the measurement frequency slightly but would greatly improve the flexibility of the control scheme.'

...That's exactly what I am doing, I posted a quick draft of the code in yesterday's post.
I just think that using PWM introduces needless complications such as lowering the PWM speed means less accuracy, whilst increasing it would cause problem with the Triac.

I have considered splitting up the bursts into smaller bundles, but for reasons of accuracy would prefer to keep it as a big chunk in the 1 second cycle. In your example you have quoted  being on for 50ms, which only gives a 'mains' burst of 2.5 cycles (at 50Hz), now are you able to energize and switch off the Triac after exactly 2.5 cycles?  Whilst if that burst was say 200ms (20 cycles) there is a better opportunity to absorb any small errors.

'...but I suppose I don't really need to know that as I'm putting power into a known load size.'

My thoughts too!

 

Paul

 

stuart's picture

Re: Solar Energy Management

Agreed, the problem with smaller bundles is the chance to miss a cycle completely, is it worth building a zero cross detector circuit??

Any luck with the electric meter testing?  Can we get away with a 1 second loop?

Paul Reed's picture

Re: Solar Energy Management

I'm using a MOC3020 opto-isolator which isn't zero-cross, but I know that other opto-isolators are (MOC3041), and provide an easy route to zero-cross switching a Triac.

Why do you think it's important to zero-cross?  I don't have a lot of knowledge of Triacs, but my thinking is that it's a non-resistive load so there will be few harmonics, it will switch on demand - not be delayed for a zero-cross, and heat shouldn't be a problem as it's only switching at 1Hz.

I haven't had chance to do a proper test yet, it may be some days before I get some time.

Paul

stuart's picture

Re: Solar Energy Management

The zero cross was purely to avoid introducing noise into the AC mains, one of the benefits of the burst controllers is that it reduces (or removes entirely) the need for AC filters.

This is quite a clear read... http://www.avatarinstruments.com/scr/scr.asp

With a variable time base, the optimum number of cycles turned on/off is achieved. This method produces less RFI line noise than phase angle fired SCRs. Power factor is 100%, while harmonic distortion is limited.

I've had a go at writing my own variable time base code, published on Github below, I could do with a scope to see how it looks, but so far its promising!

https://github.com/stuartpittaway/VariableTimeBaseSSR

 

 

Paul Reed's picture

Re: Solar Energy Management

Stuart, a zero-cross opto isolator may be the answer then.

I'm impressed with your coding skills, you are obviously well placed to develop the idea to a high standard.

Paul

stuart's picture

Re: Solar Energy Management

I'm not an electronics genius though, so a collaborative effort is probably best !!

 

I've got a better table of SSR "on/off" values to use now, amazing what you can find on the internet !

Any chance you could scribble a zero cross detector circuit diagram ?  Ideally one I can get the bits from Maplins from?

I'd like to use this to trigger an interrupt, and then use the code to turn the triac on/off as needed - so this being a "random  fire" one would be great (sounds like what you have already built)

 

calypso_rae's picture

Re: Solar Energy Management

Switching the power on/off at zero-crossing points means that the selected amount of power can be accurately delivered to the load.  If the control logic decides that 83.5% of 3kW is available, it would be nice if precisely 83.5 cycles out of the next 100 could be 'on'. 

Rather than being all bunched together, if these cycles could be distributed throughout the delivery period, that would be very beneficial.  This would allow a longer measurement window to be used, with increased resolution.  Once I have a working Mk 1 version in place, I'm keen to look into how this can be achieved.

Robin

stuart's picture

Re: Solar Energy Management

calypso, this is exactly what my code mentioned above does (hosted on github), just need to sort out the triggering of the zero cross.

calypso_rae's picture

Re: Solar Energy Management

//Can we create this table dynamically ??

My preference is for the Arduino to work out dynamically which individual half-cycles should be on/off.  Say we have a time window of 1 second, that's 100 half-cycles.  At the end of measurement cycle N, a 'power required' value will be gained, e.g. 83%.  During measurement cycle N+1, the logic would distribute half-cycles so as to continuously aim for this value.

The first half-cycle may always be 'on' in which case the rolling average starts at 100%.  100% is bigger than 83% so the next one would be off, this bringing the average down to 50%.  50% is less than 83%, so the next one will be on thereby taking the rolling average to 75%; and so on.  Using a zero-crossing trigger, the fate of the 'next' half-cycle can be determined and pre-set at any point during the previous one.  The first (or second?) change of voltage polarity would do fine.  This timing is not critical because the zero-crossing detection is done within the opto-isolator.  With an arrangement like this, I don't see any need for interrupts.

By distributing the available power in this way, the measurement window can be greatly extended - for improved resolution - without straying outside the charge-free zone.

How does this sound?

stuart's picture

Re: Solar Energy Management

I agree.

Although to save CPU power, I've auto created the "perfect" distributed bit pattern for 0-100% power usage over 100 cycles.  In theory, we could extend this to 200 cycles to give us 200 step resolution (coping with 0.5% increments or 15W against a 3000W heater).

The table takes around 500 bytes of program memory, so easily fits into the Ardunio.

 

calypso_rae's picture

Re: Solar Energy Management

As the eMon sketch already measures current and voltage many times per mains cycle, would it actually matter if the measurement frequency was slightly reduced?  Does anyone know how much delay would result for each additional statement in the main part of loop()?

Because my suggested approach does not rely on a hard-coded table, it would work without modification for any length of measurement window.  The first half-cycle of output should only be 'on' if the required power rating is 50% or over.

 

Robert Wall's picture

Re: Solar Energy Management

"Does anyone know how much delay would result for each additional statement in the main part of loop()?"

No, but you can ask it to tell you, using millis( ).

madmurg's picture

Re: Solar Energy Management

is this the type of circuit you are looking for, excuse my crude drawing.

 

http://imageshack.us/photo/my-images/593/optoisolatorzerocross.jpg/

 

 

Paul Reed's picture

Re: Solar Energy Management

Stuart, have you given any thought how this code would integrate within the existing emon code?  For example, are there any delays in the loop from other demands, such as the emon code itself, or ethernet (if using a Nanode), which could delay or influence the accuracy of the burst cycles.

Paul

 

stuart's picture

Re: Solar Energy Management

Hi Paul, I've now got a working example and code up on GITHUB.

I've calculated a table of 0-100% power usage spread optimally over 100 bits (ie. 100 ac half cycles).

I've built a simple opto-isolated zero crossing detector (using emon 9v AC power supply for the moment) and this is driving PIN 3 / Interrupt 1 on the CPU.

There is no critical code at all in the main loop of the code, all the work is done in the interrupt handler (and theres only 5 or 6 lines of code in there)

I've not connected up my SSR to the circuit yet (it was getting late!) but the output on my multimeter (has a frequency counter) looks good, with output giving a rock solid frequency signal.

I don't have a scope to check the output timings, so if anyone has one they could use to look at this code then that would be great.

My only real concern at the moment, because I'm still using an SSR (might have to swap to DIY triac) is will the SSR fire in the same zero cross that I'm detecting or will I be too late to trigger it and its a half cycle behind/in front of me?

My plans with this circuit are to integrate it totally with the O.E.Monitor building blocks and add an RFM12B transmitter so this circuit will listen to the emonTx and then set its power level according to the amount of power exported.  Addtionally I'm going to then send back to emonBase what's going on and a kWh measurement for the power I'm diverting, I've also got the mains frequency if that's any use!

Code is here... https://github.com/stuartpittaway/VariableTimeBaseSSR

I also need to build a power supply to drive the circuit from the 9v AC I'm currently feeding in.

 

calypso_rae's picture

Re: Solar Energy Management

I've just taken a home-video showing different ways of varying power to a resistive load.  I'm not recommending the use of a £70 AC-controller, but it does demonstrate the basic principles in a convenient way:

http://youtu.be/FoOniINhqTc

How can I post a picture to this forum?

stuart's picture

Re: Solar Energy Management

I think I've got the same kettle :-)

Paul Reed's picture

Re: Solar Energy Management

Stuart, that's a really great idea and would compliment & enhance the openenergymonitor modular structure perfectly.

The code that you've written is way above my abilities, but I've just changed the LED pin to 13 (onboard Arduino UNO LED is connected to 13) and loaded it up, but it does not appear to run as I expected. I get the following via the serial monitor;

 

Set value 50%
0% (0W) 0.00Hz
0% (0W) 0.00Hz
0% (0W) 0.00Hz
0% (0W) 0.00Hz
 
LED stays constantly lit.
 
Paul
stuart's picture

Re: Solar Energy Management

It needs the zero cross trigger circuit to pin 3 (interrupt 1) for the timing pulses to be generated.

Additionally, I'm using a nanode which I think the LED is inversed (on=off /off=on) compared to "normal" arduino boards.

I've used this ZC circuit, but removed the R1/R2 and fed it directly from a 9V AC power supply rather than the mains.  I also used a bridge rectifier (KBPC104) instead of D1-D4, and swapped the optoisolator for SFH618-2. 

All parts were brought from Maplin, ironically the bridge rectifier was cheaper than buying 4 seperate diodes!!

http://www.dextrel.net/diyzerocrosser.htm

Paul Reed's picture

Re: Solar Energy Management

Aahh, that makes sense! - for some reason I didn't think that you were using zero-cross in this version, and yes I had switched the inverse (Nanode/Uno) LED.

Because PIN3 is currently unconnected, it is picking up noise and occasionally firing at random, but I obviously need the zero-cross circuit to run it properly.

Thanks Stuart

Paul

calypso_rae's picture

Re: Solar Energy Management

My circuit can now vary power to a 3kW load on the basis of the current in a test circuit.  Nothing new, just an assembly of standard principles.  If anyone is interested, it can be seen at  http://youtu.be/w0OpfWBmYz8

SolarDumper's picture

Re: Solar Energy Management

Hi All

You may want to check out this on Google. 

Using Hardware Interrupts to Control A.C. Power with Arduino

The whole website is very good I currently have this circuit being driven by the original OpenEnergyMonitor sketch written by Trystan Lea. I have replaced the 10K pot with a light dependent resistor shrink wrapped with a LED driven by a second Aruino running Trystan's sketch. Solar - load gives me a number to drive the LED via PWM.

However, my method of driving the load is to wait until I have a 150W surplus and then drive the triac at 43V (100W ) wait until I have another spare 150W, then drive the triac at 62V (200W) in stages all the way to 3kW. In this way I am always 50W in hand driving the load up and down in 100W stages. Of course any value could be used in the sketch to suit your requirements.

Regards, SolarDumper

stuart's picture

Re: Solar Energy Management

Good link, think I have read that before.

The only difference between what I'm trying to do and that site/code is to produce a better "burst fire" control method instead of just on for X cycles, off for Y cycles.  This is meant to be better for the heater elements to avoid long term fatigue.

 

fewyatt's picture

Re: Solar Energy Management

Quote “so for 20% power, the SSR is switched on for 200ms and off for 800ms”

Interesting discussion I have just joined. I tried something like this last year. It causes the lights to flicker. Indeed the neighbours’ lights were flickering too and she blamed it on me even though she did not know I was experimenting with this. Had to give up the experiment because she is a difficult character. I have doubts it is legal to use burst fire technology unless pulsing is very fast (too fast to get a reasonable range of mark space ratios) or very slow (too slow to spoof the meter) so mains fluctuations are not noticed. What regulations apply?

Even spacing the mains cycles out to say

on on on off on on on off on on on off on on on off on on on off

rather than

on on on on on on on on on on on on on on on off off off off off

may not eliminate flicker because as little as one half cycle skipped can cause flicker. May work on a 100W light bulb but a 3kW heater is a lot more current.

Also whilst some electricity meters may ignore the alternating import and export can we be sure that all do, e.g. the wheel type meter I have?

stuart's picture

Re: Solar Energy Management

If you read some of the earlier posts, there is vast discussion about the use of  electric meters and how the more modern ones measure energy usage.

To do burst fire correctly it needs to detect zero crossing of the AC cycle and then energise the relay at that point, you will still get flicker if you were to look at the output on a light bulb/led for instance - but this is all about driving a heating source and that wont flicker!

Once you are triggering correctly, then you are not going to be skipping cycles.  I'm currently working on switching half cycles so using a single full 50hz cycle ie. pulses spread over 1 second interval.

 

 

fewyatt's picture

Re: Solar Energy Management

I get the theory for digital meters (assuming they all work in a similar way) but for wheel meters I am not so sure. Mine works on proportional control but might not on burst firing.

I was using zero crossing but don’t think it actually makes any difference as far as light flickering is concerned. Light flickering is caused by the large on or off periods in the mark space ratio which makes the mains voltage fall or rise significantly for a significant time. Not a problem to making the immersion correctly work, but is to keeping the utility company and neighbours happy and avoiding court cases.

 An expert told me that you can’t get CE approval for burst firing. Maybe can in a factory as uses different regulations but not in domestic premises.

 

 

stuart's picture

Re: Solar Energy Management

Not so sure about the CE marking, if you look at these..

http://uk.farnell.com/controllers-burst-firing

They are all burst fire, and all CE marked.

 

Zero crossing should reduce the amount of interference, if not then you'll need something like this:

http://uk.farnell.com/crydom/1f25/filter-ssr-1-phase/dp/1200270

 

calypso_rae's picture

Re: Solar Energy Management

I've just boiled up a cuppa using a 3kW kettle in burst-mode with no adverse effects on Classic FM or Radio 5 Live on good old-fashioned radio.  The kettle appears to have survived the experience, and so far the neighbours haven't complained ...

fewyatt's picture

Re: Solar Energy Management

EMC is a big subject but simply wiring a circuit together out of CE marked components does not always give you a system that meets the regs, e.g. phase angle control at 3kW on a CE marked SSR does not meet any known EMC regs, so will not be a system that can be CE marked. It takes the addition of a filter to pass EMC regs. So what does it take to get a CE marked burst fire controller to pass relevant regs that would enable a CE mark to be added to the system?

 I guess it may be more to do with what the utility companies allow than EMC regs, as we are talking about sub 50Hz pulsing and not radio interference. But don’t assume there is no RF as even an always on SSR distorts the waveform and without a simple filter may produce more than the EMC limit.

 Also beware that manufactures may be claiming CE based on industrial standards that don’t apply to domestic applications like ours. There is also the infamous CE clone mark that stands for China Export, i.e. made in China and not proven to comply to any EU standard.

 Calypso, does an incandescent bulb in a normal light fitting pulse/flicker? In my case it was even in the neighbour’s house, although not by a huge amount.

glyn.hudson's picture

Re: Solar Energy Management

Hello everyone, 

I've just had a quick catchup on this thread. It's fantastic that the discussion and development is progressing. Stuart's code looks very interesting. I really like the sound of what Stuart had in mind. I would love to see a unit to control an immersion heater with an Atmega328 and RFM12B receiving data from the emonTx and posting data to the emonBase. This unit would integrate well into the current system. 

Looking forward to following developments, keep up the energy, no pun intended! 

markbeal2's picture

Re: Solar Energy Management

What about trying washing machine filters? They are rated at about 16A and filter the noise created by the triac controlling the drum motor. They usually have an earth connection which needs to be in circuit, other than that they are Live and neutral in and the same out.

My unit consists of a "Kemo" M028m 4KW power controller with the "Kemo" M150 Auxiliary module: DC and Pulse Converter.

http://www.kemo-electronic.de/en/Light-Sound/Effects/Modules/M028N-Power-control-110-240-V-AC-4000-VA.php

calypso_rae's picture

Re: Solar Energy Management

Sorry, my burst-mode powered kettle doesn't cause any lights to flicker.  Being a pricey piece of kit, the AC controller that I'm using is presumably EMC compliant.  It is 30A rated, and I'm never using more than half of this.

Once I start playing around with triacs and the like, things nearby may well start to be affected - but hopefully not the neighbours!  I like the idea of switching at zero-crossings which should minimise any interference.  One reason is that I would expect a zero-cross system to be more linear than a phase-controlled one.

stuart's picture

Re: Solar Energy Management

Quite a few sites on the web that supply or make the burst controllers state that they usually don't require any filters, due to the zero crossing.

 

bommels's picture

Re: Solar Energy Management

My experience using this controller:

http://www.gavazzi-automation.com/pressdescr.asp?ID=6

It can do phase angle as well as burst fire. Phase angle control resulted in a noisy immersion heater, so I am using burst fire, which is silent, and has not resulted in any apparent interference issues, even with the cable between the controller and the heater being quite long and running diagonally through the house.

In burst mode, the neon load indicator lights flickers visibly; from the pattern you can see that it regulates the power by spreading the active cycles around evenly. For example, if 2/64 power is required, it fires 1 pulse every 32 cycles rather than 2 consecutive pulses in a 64 cycle pulse train. 13/64 power requirement results in interesting rythmical patterns!

The downside of the system is that it takes from 1.28 up to 2.55s to propagate power changes: the emon accumulation should now be 64 cycles long to properly sample the power controller switching, taking 1.28s. If the arduino sets the new required power level, and the controller has just started (worst case) a pulse train based on the previous setting, it will take another 1.28s before the power level is adjusted.

This makes the case for the dynamic power control as discussed above. It might be a bit more tedious to implement, but it certainly has advantages.

And yes, admittedly the controller was not cheap (£65 at RS components), but considering the domestic hot water electricity bill is estimated to be well over £100 annually, it will probably have earned itself back before the end of summer.

stuart's picture

Re: Solar Energy Management

Brilliant info thanks, just the advise I needed to give me the motivation to finish the project !

As my burst fire solution is in code, I can swap power levels mid pattern, so should have fairly quick change up/down.

 

calypso_rae's picture

Re: Solar Energy Management

Our house has just gained a new sound, that of the immersion heater gently heating up our DHW cylinder for free.  Music to my ears!  Today's sunshine has produced copious hot water for the washing machine and the dishes, with plenty in store for an inaugural solar bath tonight.  This control system has really brought our PV to life - it's now clearly doing something useful, rather than essentially just being a financial investment.  Thanks to everyone who has helped me get this far.

If anyone is interested in the technicalities, feel free to ask away, either here or as a PM.

PS. It would be nice if my control system could be powered down whenever the PV is not on.  This could be achieved by monitoring a front-panel LED on the inverter and switching power to the rest of the control system via a relay (or triac?).  Has anyone done this already? 

 

Paul Reed's picture

Re: Solar Energy Management

Are you using Stuart's burst-fire sketch/circuit?

calypso_rae's picture

Re: Solar Energy Management

No, I'm using a Carlo Gavazzi AC controller in Mode 2 which distributes whole-cycles evenly over a 64-cycle window.  This is the same piece of kit as described by bommels a few days ago.  It comes with a large heatsink, presumably needed for when switching big loads in phase-angle mode.  In my case, with only 3A being switched and always at zero-crossings, it's barely  warm.  My mains transformer is considerably warmer which is why I'm keen to have the system turn off when the PV is inactive. 

 

stuart's picture

Re: Solar Energy Management

I've started a new thread off to prevent polution of this one on my build...

Paul Reed's picture

Re: Solar Energy Management

Where? have you a link Stuart.

Paul

stuart's picture

Re: Solar Energy Management

Anonwelder's picture

Re: Solar Energy Management

Homer Controller.

 

Over the last few months, a mate and me have used Paul's Solar Power Manager project to make fully working controllers which use PWM from an Arduino to control the immersion heater.

Heater Operation Manager / Export Reducer (Homer) uses an SSR to send 'spare' solar to a 3kW immersion heater. Our PV systems are 2.5kW and 2.75kW.

Obviously, Paul's design had a two stage heater switch on via relay, but most of the time and especially with the weather of late, I would not be able to send anything the the heater.

First consideration was to use a dimmer, but abandoned this due to various reasons, heating of the dimmer being the primary.

Next we considered triacs and with all the comments about being able to switch this reliably was not sitting particularly well either, so we opted for SSR.

One observation regarding my grid-tied PV installation is what my electric meter (digital) did and also that of the analogue meter of my mates did- they do have a 'sweet spot' where they register reverse energy (mine shows RED- Reverse Energy Detected) and my mates went backwards for about a quarter of a turn, then hit a backstop. What we did next was to exploit this in the way the project works.

The eureka moment was to use the 'sweet spot', to our benefit.

We pulse the heater with any spare solar, but if you over-use by a little, allow this back into the meter, then maintain within this zone at all times. Home energy demand is continuously monitored, so if you were to switch on a kettle, Homer stops diverting power to the immersion within a second while the kettle heats, then resumes diverting once again when the kettle switches off, for example.

This is done with an Arduino Uno, one SSR, one current sensor (yes, it just needs one as a diverter, two if you want to show PV production too) as a basic, but we've both added LCD displays and a logger shield.

My total export since install on 28th April has been around 3kW, mainly due to me neglecting to refit a current sensor one day, (doh!) the rest was due to tank being at full temperature. The resolution of the system being 15 watts shows how efficient this system is.

Our thoughts regarding in-depth discussions regarding cross over timings and throwing extra (expensive!) components at it may well work, but forget it, you are over complicating things.

Look at your meter when you are exporting- it will go backwards slightly, so use this approach instead. As for noise of pulsing anything mains powered, my daughter's hair drier is worse that anything at blacking out the digital TV signal! Noise really isn't an issue if appliances like that are on sale.

The proof that this system works is to read my utility meters. They have not reversed direction, but my import has reduced markedly( through having solar anyway), but gas consumption is way down on same period last year , having not changed anything else in the home.

Food for thought. Will post photos etc soon.

 

AW & DLB

 

 

Lloyd's picture

Re: Solar Energy Management

I'm trying to understand (and replicate) madmug's circuit (http://img832.imageshack.us/img832/4938/circuitx.jpg) which is referenced on page 1 of this long thread. Analog electronics is not one of my strong points so please bear with me.  Looking at the circuit, my logical mind would  have thought that the 10v that the triac required, would have been delivered by connecting the collector of transistor 2 to 12v, but it is connected to Vin (3.3v).  Would someone mind stepping through exactly how it should work, as I can't get my replica to function correctly.

Many thanks

Lloyd

madmurg's picture

Re: Solar Energy Management

The 12v is connected to the collector it is also connected to vin which is what powers the arduino

Lloyd's picture

Re: Solar Energy Management

That makes more sense - I misunderstood the way it was drawn.

Thanks

Lloyd

Lloyd's picture

Re: Solar Energy Management

Now I have the circuit working, one further question. Your choice of 47uF capacitor seems quite high from the simulation I have done with LTSpice - it introduces a fair degree of lag - and was considering lowering it to 10uF.  What determined your choice of value?

Lloyd

madmurg's picture

Re: Solar Energy Management

I think 10uf will be fine I used the 47uf as it was the only one I had to hand, seems to work ok though.

calypso_rae's picture

Re: Solar Energy Management

My Mk1 system is now working nicely "for real" in the garage :) 

http://youtu.be/-lk6Me3cwuw

In weather like this, we could do with a larger water tank.  The system gets to max temp by around 11am.

madmurg's picture

Re: Solar Energy Management

Wow its huge, good job its in your garage.
Well done anyway for getting it up and running

calypso_rae's picture

Re: Solar Energy Management

Sure, Mk1 has a certain presence but the important bits are only small.  The stuff in the background is just for powering the commercial AC Controller.  An old model railway power chassis was readily to hand, so why not make use of it.  Anyway, the big neon glows nicely in the dark 8-)

My Mk2 version will be a lot neater ...

glyn.hudson's picture

Re: Solar Energy Management

Great explanatory video. It's been a good few days for testing solar PV electric immersion heater control in the UK! Looking forward to MK2. Have you published your Arduino code anywhere? 

calypso_rae's picture

Re: Solar Energy Management

Hi Glyn,

My code is nothing special, but anyone is welcome to look at it.  Maybe you could PM me as to how I can publish it.  I don't understand Github.  Or maybe my sketch could just be posted here as an attached file?

glyn.hudson's picture

Re: Solar Energy Management

Github is best, I know its a bit of pain to setup but it does work very well when its up and running. I find it useful as a personal revision management tool. Depending on your OS there are lots of good git tutorials online. If you use windows I've heard this tool can make it quite easy http://haacked.com/archive/2012/05/21/introducing-github-for-windows.aspx, I've not used it myself. I use Linux Ubuntu, git works quite well in terminal. 

Or if you prefer just attach a zip onto a forum post. Make sure you tick the 'list' box to make it show-up. 

calypso_rae's picture

Re: Solar Energy Management

My sketch is attached as a .zip (Mk1_in_Garage_2.ino).

The call to calcVI() is as given in the standard sketch.  Maybe the first parameter should be changed to 128, i.e. 64 wavelengths to align with the CG's distribution window when in Mode 2.  At present, I think it's running until the 2-second timeout.

pmcalli's picture

Re: Solar Energy Management

Looking at solutions on this site I feel I have to make a comment on the design approach hopefully nobody will be too offended.

everything on here is driven by a digital approach which has some serious flaws whereas a better solution could be obtained by a mixed signal design. I have designed an immersion controller using an analog approach which has none of the digital defects ( sampling rate sensitivity etc ) and only uses two chips. It strikes me that a combination of the energy monitor and the analog power measurement/control circuit would be a better solution. the performance of my system over the last 9 months is all but 50W diverted to immersion and no forward meter movement on mechanical or digital meters.

My expertise is in rf, microwave and analog circuit design. playing with software isn't really my thing so if anybody is interested to work with me to combine my analog design with the monitor please contact me.

madmurg's picture

Re: Solar Energy Management

I think i have seen your circuit, doesnt it still use the crydom proportional controller?
The recent circuits being used on this thread do away with the need for an expensive crydom controller.

jimjam's picture

Re: Solar Energy Management

stuart i have just set up your circuit and used your sketch using an arduino with the output connected to pin 3.

I dont seem to be getting any outputs on the serial monitor ie

 

Press letters u to increase power (up), d to decrease power level (down), 0 = off, 5= 50%, 1=100%
Resolution=0.50%
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz
0.00% (0.00W) 0.00Hz

am i missing something.

calypso_rae's picture

Re: Solar Energy Management

jimjam - if you're not seeing any Serial data, maybe you should try using one of the standard sketches on the website.  Then, when you're happy that you can measure and display voltage and current to your satisfaction, you can migrate towards the more complex setup that you really want to get working.

If something won't work for me, I often 'home in' on the problem area by using some quickly assembled Mickey Mouse code rather than the Full Monty! 

Phill W's picture

Re: Solar Energy Management

Wow Robin, you certainly cracked on!

I have been somewhat out of the loop recently with work commitments. Now back and you have certainly inspired me to get on...... unlike the weather!

My first stumbling block was getting the op amp to work!

Can I power the op-amp from the same power supply I will use to power the Arduino?

Anyone got any practical advice for setting up the op-amp? I want to convert the 0-5V output on the Arduino to 0-10V for the Crydom controller.

feelin' good to be back!

calypso_rae's picture

Re: Solar Energy Management

Hi Phil W, No, there's not much useful power to play with at the moment.  My PV generated just 1kWh yesterday, and no obvious heating of water took place :(

For the record, my Mk1 system uses two op amps.  One is to buffer the 2.5V reference so that it can be shared between two or more sensor circuits.  That op amp can be conveniently run from the +5V supply that's available on the Arduino board, details at  http://openenergymonitor.org/emon/node/673

I use a separate op amp to convert the 0-5V signal from the Arduino (PWM, smoothed) into a 0-10V signal for feeing into a Carlo Gavazzi controller which has a similar input requirement to the Crydom.  As the output from this second op amp needs to swing between 0 and 10V, I've used an LM358 'single rail' device running off a regulated 12V supply. 

In my case, this 12V supply does nothing apart from powering this op amp; my Arduino runs off a standard 9V 200mA DC adaptor which was convenient.  An alternative approach would be to create a suitable supply for the voltage-doubler circuit, and then step this down to something lower for feeding into the Arduino's Vin socket. 

A single transformer may be able to provide everything you need: 12V for the voltage-doubler, 9V for the Arduino, and also a suitable AC signal for the voltage sensor, details at http://openenergymonitor.org/emon/node/704.

Hope this helps, Robin (calypso_rae)

jimjam's picture

Re: Solar Energy Management

Hi robin can you post your pwm smoothing circuit also can you elaborate more on how you calculate how much solar you have to play with as i see you only use 1ct. Do you monitor the light on your energy meter and then know when you are importing or exporting.

calypso_rae's picture

Re: Solar Energy Management

Hi jimjam, For smoothing the PWM, I'm just using an RC low-pass filter.  The Arduino's output pin (pin 9 as per the PWM examples) feeds a 22K resistor, after which there is a 10uF capacitor to ground.  The signal then goes into the +ve input of an LM358 op amp in x2 mode.  At the amplifier's output, there are two 10K resistors in series to ground, with the mid-point being linked to the -ve input of the amp.  The amp's output goes straight into the Carlo Gavazzi controller's input, as it presumably would with a Crydom.  The CG also requires a 24 Vss feed, either AC or DC; I've gone for the AC approach, but I know that others have successfully used it with DC. 

To decide how much surplus PV power is available, I simply measure AC current and voltage at the grid-connection point.  The Arduino calculates the real power (emon1.realPower in the Voltage And Current sketch), and diverts all but around 50W to our immersion.  Simple.  I don't measure how much power the PV is generating because this information can be read from the inverter's display.  And I'm not really interested in how much power the house is consuming at any time.  If an appliance is on, then it probably needs to be on.  I just want to make sure that the PV energy which we generate gets used on-site if possible.  In good weather, our water tank gets to max (70C) by around 11am, so the more loads of washing that we can run through the system the better.

Monitoring the supply meter's LED is an interesting concept.  While illuminated, that LED shows that we're exporting, so no problem.  But if someone puts on the Hoover or similar, then the LED may go out.  All being well, the control system will rapidly detect the net inflow of power and reduce power to the immersion so as to reinstate the desired level of export to 50W.  One possible approach might be to immediately kill all power to the immersion if the supply meter's LED ever goes out.

Monitoring the LED on our inverter's front-panel may be a useful development.  This LED is only on when the PV system is active.  When the PV is inactive, it would seem sensible to power down the entire monitor&control system until next day.  The only circuitry which needs to remain on 24/7 is a sensor to monitor this LED, and the means to power up the rest of the system when the LED comes on.

calypso_rae's picture

Re: Solar Energy Management

for some reason, that message got posted twice ... sorry

jimjam's picture

Re: Solar Energy Management

Im still a little confused, you say that you have your ct at the main incoming tails and you measure real power at this point.
How do you know if you are importing or exporting when you take the measurement, surely the ct shows a reading when you are importing and when you are exporting or does the ct only work one way round.

daveb's picture

Re: Solar Energy Management

I've added comments to the second thread http://openenergymonitor.org/emon/node/685 , but I have a design for a phase controlled triac that works with my spinning disk meter. I don't have a way to verify this with a more modern meter.

http://www.rotwang.co.uk/projects/triac.html

I would be interested if anyone would be able to verify this works with a modern meter. Feel free to contact me offline at solar at rotwang dot co dot uk

I'm still concerned that success may be short lived as utility companies adjust to the idea of people having generation capability. The imminent roll-out of smart meters across the country might kill this idea dead.

An alternative technique, that I'm interested in exploring, would be to rectify the mains using a diode bridge, then chopping it with a FET or IGBT into a filter. The filter can store the excess energy during the 'on' phase, resulting in an even load on the import meter. This would work with any meter.

Has anyone tried this? It will obviously only work with loads that aren't fussy about using AC. A kettle or an immersion heater shouldn't care.

calypso_rae's picture

Re: Solar Energy Management

Jimjam, if you read back though this thread and others, this aspect has been well covered.  To distinguish between inflow and outflow, you need to measure both current and voltage and then compute 'real power'.  Using the standard V & I sketch, 'real power' can be obtained after calling calcVI() using the construct emon1.realPower, as in my published sketch.

jimjam's picture

Re: Solar Energy Management

Sorry if i am a bit thick. I understand how you calc real power but i still dont understand how you know when you are exporting to the grid. Surely you only want to power your immersion when you are exporting. Thanks for your patience. Please can you explain in layman's terms.

Robert Wall's picture

Re: Solar Energy Management

Jimjam,

The sketch that calypso-rae mentions measures voltage and current about 50 times for each cycle of mains. When power is flowing one way, voltage and current rise and fall together. So if you think of  the voltage and current drawn as a graph against time (see here: http://openenergymonitor.org/emon/sites/default/files/resistive2.jpg), you will have 50 measurement points of each on the graph. Both current and voltage will have the first 25 points above the zero line - the values are positive, and then 25 points that are below the zero line - the values are negative. Power is voltage  x  current, so power is always positive.

When power is flowing the other way, the voltage wave is the same as before, but current goes in the opposite direction. So the current wave (the blue line in the graph) is upside down. For 25 points voltage is above the line and positive while current is below the line and negative, and then for the next 25 points voltage is below the line and negative while current is above the line and positive. Now the power is always negative.

So you know the direction of the power flow because the power will be positive one way and negative the other.

You could always try it! Load the sketch into your emonTx and see what power it shows. Then unclip the current sensor and reverse it on the mains cable, and you should read the same power but the opposite sign. By reversing the current sensor, you have made it look as if the power is flowing in the other direction.

If you don't measure voltage at the same time as current, you don't know how the waves relate so in that case, you cannot know which direction power flows. When you measure the voltage, you can know.

jimjam's picture

Re: Solar Energy Management

Ahh thanks very much the penny has now dropped

calypso_rae's picture

Re: Solar Energy Management

Nice One Robert, cheers :D

543bill's picture

Re: Solar Energy Management

HI!

I am just getting started but do not want to take the programming route. I have just installed

an Eco-eye PV  for monitoring..this gives historic tracking of PV and House data and real time

traces so I can now see the PV output and the impact of house loads in real-time.

I have been monitoring the immersion dumping activity on forum sites since late last year

while awaiting availability of Eco-eye PV . I noted some mention of differential amps driving a triac

and copied a circuit but do not have the source. Most of the hardware activity seems to be on

Navatron.

rgds

 

Bill

 

 

fewyatt's picture

Re: Solar Energy Management

Bill how are you finding the Eco Eye PV? I got one 2 weeks ago and it’s proving extremely flaky with non working voltage sensor initially, display freezing up regularly, rebooting itself and PC Trax software not reliable either.

eof's picture

Re: Solar Energy Management

Wow, what a thread.  It's really re-kindled my interest in immersion heating from PV.

The zero crossing detector is a real find.  I'd thought of accumulating the power over a half-cycle to provide a brief pulse to the LED at zero-crossing for efficiency, but it's nice to find a finished and extremely well-documented project.

I am in the position of not being able to measure house current, so I need to know the direction of power flow in the meter tails.  I imagine that if your mains supply is good (no worries about burst firing causing your neighbours' lights to flicker!), the voltage waveform is going to be pretty clean, so there is no need to obtain a facsimile of it.  Instead, you could modify the zero crossing detector to be half-wave, giving you the phase information you need by having a pulse only once per cycle.  Simple timing can generate the other pulse if you need it.  You then synthesise the waveform in software to get your import/export power from one current transformer and a zero-crossing detector.

I accept that you don't get a value for mains voltage, but in my case I'm already interfacing to my PV inverter, which tells me this.  I'm using a Sheevaplug plug computer to log PV and weather station stats, and I'm considering using this to control and log the immersion heater too.  It knows when the inverter has shut down (no data appears) so this can be used to save a bit more power by stopping the immersion heater software too.  Well that's the theory!

calypso_rae's picture

Re: Solar Energy Management

Building your own zero-crossing detector may be an interesting project, but there are already plenty of inexpensive devices on the market which do this.  I've just bought a couple of triacs and z-c trigger devices for under a tenner but have yet to fire them up.  Working out exactly when to switch them on will be interesting!

When measuring power using a c/t (which can only measure current), there are two good reasons to measure voltage too.  The first is that power can be more accurately assessed if the actual voltage is known rather than using some nominal value.  The second reason is that knowing the phase relationship between V and I allows the direction of the current/power to be ascertained.  This approach will work anywhere in your house, not just at the meter point.

Sorry, but I don't follow your ideas about synthesing a waveform in software.  Isn't the best plan just to activate individual mains cycles at the right rate for the prevailing conditions, preferably using a £15 Arduino rather than an expensive piece of 3rd party kit?

jimjam's picture

Re: Solar Energy Management

I have just aquired one of these from ebay for £11

 http://www.surecontrols.com/support/manuals/eurotherm/425aops.pdf

Four thyristor firing modes are available:
• Phase angle - thyristor firing angle variation
• Single cycle (cycle time 40 ms at 50% power)
• Fast cycle (cycle time 320 ms at 50% power)
• Slow cycle (cycle time approximately 10 s at 50% power).

can someone who is more savy than me advise me on what the best way to control this bit of kit.

eof's picture

Re: Solar Energy Management

I like the elegance and efficiency of the zero crossing detector in the link.  A simple resistor in series with an opto-isolator LED is relatively inefficent and subject to drift as the LED ages if you tweak the resistor value to try to reduce the time the LED is on (and hence the power dissipation).  If there's a cheap ready-built module that performs as well then I'd be happy to use it.

My situation is that I already have a Sheevaplug powered 24 hours a day to do inverter monitoring, weather station data collection, file serving, etc.  The issue of its cost is therefore irrelevant.  If I were starting from scratch then I'd definitely go down the Arduino route, but I'm not.  I would like the Sheevaplug to do the processing the Arduino would do.  As it is a fully multi-tasking Linux box, this may or may not be practical.

Because the Sheevaplug has an RS485 data feed from the inverter, I know the mains voltage accurately as this is one of the parameters it supplies.  So, assuming that the voltage waveform is sinusoidal, I can use the zero-crossing detector to trigger an iteration over a sinewave look-up table to multiply with the current transformer readings and sum to calculate power.  I would hazard a guess that this is more accurate then getting a voltage waveform from a small transformer - I have read on here about pitfalls with that (distortion and phase shift).

As to direction of power flow, I think you missed the point I made before: modify the zero-crossing detector to give one pulse per cycle rather than two, and you have the phase information you need to determine the direction of power flow.  I need to do this as I don't have access to a house current measurement.

Incidentally, I don't think that the mains voltage varies much, although I need to confirm that by analysing my collection of nearly a year's worth of inverter log files (recording parameters every ten seconds while the inverter is active).  If you are in a rural setting at the end of a long piece of 11kV overhead line, your situation may well be different, and your neighbours' lights may also flicker if you burst-fire your immersion heater...

As I don't have ADCs built into my Sheevaplug, I'm considering using a USB "sound card" to do this.  I would feed the current transformer into one channel and the zero-crossing detector into the other to ensure that they remained in sync.  Every so often I would grab a cycle and calculate the power.  Experimentation required!

Interesting point from the SCR tutorial linked somewhere in this thread: SCRs are more efficient than triacs because they have a smaller voltage drop, so better to use two back to back than one triac if you want to reduce heat dissipation.

stuart's picture

Re: Solar Energy Management

Are you suggesting that by knowing the zero crossing point on the AC cycle, and the current (from a CT sensor or direct from the inverter) you can calculate the direction of current ?

Additionally, be careful about switching half cycles into a heating element, as you are then driving it like a DC unit, rather than an AC one and I expect this will cause it to reach its end of life quicker.

eof's picture

Re: Solar Energy Management

The direction of power flow, yes.  If you get a pulse at either the positive or the negative zero crossing point of the mains, but not both, that tells you the absolute phase of the voltage waveform.  If you know in addition the RMS (or peak) voltage and the frequency, and you assume that the waveform is sinusoidal (which it ought to be, unlike the current waveform which could be going all over the place), you have all you need to synthesise the voltage waveform exactly.  As you know, multiplying current samples by voltage samples over a complete cycle and summing them will give you the net power, with its sign indicating the direction of power flow, however odd the current waveform (assuming your sample rate is high enough to capture all its significant harmonics).  Whether you do this with a real feed of the voltage waveform or a synthesised version which is identical obviously makes no difference.

The most efficient way to implement this in software is to have a lookup table holding a quarter of a sinewave, with the number of values being the number of samples your CT ADC produces in a quarter of a cycle (5ms @ 50Hz).  When you get a zero-crossing pulse, clear your total and start to traverse the lookup table, multiplying each value by the current sample and adding to the total.  When your reach the end of the lookup table, start to traverse back towards the beginning, as the second quarter of a sine function is the same as the first, mirrored in the y axis.  When you get to the beginning again, start to traverse to the end, but this time subtract your products from the total, as the third quarter of a sine function is the same as the first, mirrored in the x axis.  Finally, traverse back to the beginning, again subtracting your products from the total, as the fourth quarter is the same as the first, mirrored in both the x and y axes, or on the diagonal if you prefer.

The final step is to multiply the total by the peak or RMS voltage measurement (scaled appropriately) and bob's your uncle - a figure whose magnitude is the power transferred in that cycle and whose sign is the direction of power flow.

I am not going to be putting half cycles into a heater.  It is trivial to synthesise two trigger pulses per cycle from one zero crossing point and I would always trigger complete cycles.  I doubt that a DC component will do any harm to the heater, but it is certainly an antisocial and I gather illegal thing to be doing with the electricity supply.

Robert Wall's picture

Re: Solar Energy Management

"Incidentally, I don't think that the mains voltage varies much...."

Perhaps yours does not, but it can vary from the nominal standard (assuming you are in the UK) of 230 V by -6% to +10%. It could therefore be 10% down, or nearly 6% up, on the normal centre value of 240 V.

 

eof's picture

Re: Solar Energy Management

Well yes and no.  Those figures do not really represent how much your mains voltage will vary from day to day, but are a fudge to ensure that certified appliances will work across the EU where different countries' nominal voltages range from 220V to 240V.  So you may only need to measure it once.  Power consumption meters that don't plug in, like the Owl, can only operate with an estimate of voltage.  You can tell the Owl that your supply is either 230V or 240V.  Mine is 240V and is unlikely to change unless they have any reason to replace the substation transformer.  I would hazard a guess that the inaccuracies you will get from sampling the voltage waveform through a small transformer are going to be at least comparable to synthesising a waveform with a fixed voltage.

I have already mentioned that some people's supplies will vary more than others - and that the ones that vary most are likely to have relatively high impedance, meaning that it may not be a good idea to burst fire immersion heaters off them because it will cause lights to flicker.  When I get the time, I shall analyse my getting on for a year's worth of daylight voltage readings at 10 second intervals and be able to tell you just how much my supply does vary.  I am afraid I won't be able to tell you the voltage at midnight though.

Robert Wall's picture

Re: Solar Energy Management

I'd be interested to see that - but the "wee small hours" readings would be quite interesting too. I assume you are in an urban area (like me).

eof's picture

Re: Solar Energy Management

Voltage distribution graph attached, from about 1.25 million samples.

As you can see, for the vast majority of the time it's within +/-5V of 240V (+/-2%).  The graph extends to the limits of the voltages measured, and the ones at the edges look like freak values.  The lumpiness I attribute to ADC non-linearity.  I am indeed in suburbia, close to a substation, and would supply overnight figures if I had them but I don't because the inverter is asleep.

fewyatt's picture

Re: Solar Energy Management

I complained to my electricity company because my voltage was often over 250V and I was worried about it shortening the life of my bulbs, etc. and using more watts. 

They fitted a sampler in the meter cupboard for 2 weeks, and although I did not see the detailed results, they claimed it was always in spec, but just. So they were not going to take any action to alter it at the substation. I concur though that the day to day / sample to sample variation is not large, perhaps within +/- 2.5V most of time and I am one of the furthest from the substation. Although I am sure if you went to a different town and measured it you could find it >10% lower.

markbeal2's picture

Re: Solar Energy Management

The problem is Fewyatt is with the generation from PV. This generation is relatively new to the grid system but is being monitored by various institutions such as universities; solutions to many of these things will come to light.

It's a very difficult job distributing electricity and keeping every one happy; the rms readings will be within tolerance if they say so as results have to be logged. I can't say to much as I work for one of the electricity distribution companies and wouldn't want to incriminate myself.

eof's picture

Re: Solar Energy Management

But how can the high voltage be blamed on PV generation, when it doesn't go back to normal at night?

Paul Reed's picture

Re: Solar Energy Management

fewyatt -  In Great Britain domestic supplies must be maintained within the range 216 volts to 253 volts, corresponding to a nominal value of 230 volts, minus 6% to plus 10%. So unless your supply is more than 253 volts, I doubt that any action will be taken by the electricity company.

markbeal2's picture

Re: Solar Energy Management

Paul is correct Fewyatt; I calibrate our energy monitors once a year and they are very accurate even on current as well.

jollygreengiant's picture

Re: Solar Energy Management

If you are in need of an affordable product that will monitor and control the power generated by your renewable energy source please have a look at www.totalpowershop.com and the TP-S610A power / energy management unit

It will monitor how much energy your house is consuming and how much power you are getting from your solar panels or any other renewable energy source. It will automatically switch on up to 3 other appliances when enough surplus energy is being generated.

And its only £300!! It should pay for itself as well, although it may take a year or two to get the money back. And it will make sure that your home is not consuming anymore power than you want to. The control unit will also record your energy production and consumption and download it to a pc.

eof's picture

Re: Solar Energy Management

Erm, £420 for the equivalent of an Arduino, a current transformer and three remote controlled mains sockets?  I don't think so!  Kindly take your spam elsewhere.

Paul Reed's picture

Re: Solar Energy Management

There is a massive void at present of people who have the same goal as us, yet lack the technical knowledge/skills to build such a device, and if this meets that demand, then I applaud the initiative. At least it's cheaper than EMMA!

Unfortunately the totalpowershop website does not provide enough technical detail to determine if it's a serious device or a toy. 
I personally always assume that such devices are toys unless there is some transparency in how it works & operational specifications meet expectations.

eof - by coincidence a similar post has appeared here - http://www.electriciansforums.co.uk/central-heating-systems/23969-immersion-heater-pv-electricity-22.html   - quote 'Good news is that this unit is reasonably priced too:'

Paul

eof's picture

Re: Solar Energy Management

You are more charitable than I... this guy can't even be honest about the price, as £300 buys you nothing more than a "limbless" central controller, which is incapable of any "monitoring" or "switching", however many exclamation marks are used.

Yes, weird co-incidence that other posting has appeared.  And it is indeed much more reasonably priced than the above - £155 for everything rather than £420.  A question remains over whether it can measure the direction of power flow in a meter tail and hence whether it's suitable for systems with a single consumer unit.  I've asked that question on eBay.

Robert Wall's picture

Re: Solar Energy Management

Is it another coincidence that "jollygreengiant" had joined only 8 minutes before that was posted, or am I being a cynical engineer again?

eof's picture

Re: Solar Energy Management

I did wonder!  Incidentally, solarcontrol has promptly and convincingly answered my question on eBay.  I think £155 is not a bad price at all for what you get.  Of course it's only able to make step changes to the house load and it isn't measuring real power, but it should be useful to some people who don't want to build it all.  Not at £420 though!

calypso_rae's picture

Re: Solar Energy Management

Switched-on PV owners need a reliable Arduino-based design which uses a standard triac to route surplus power to a dump load.  Apart from the current clamp, there should be just one connection to the mains, and the total cost should not exceed £50.

Watch this space (but probably on a new thread ...)

jollygreengiant's picture

Re: Solar Energy Management

I am sorry for my enthusiam.  Perhaps if I explained my story. 

Wanting to be a bit greener and to reduce my energy bills I had solar panels build into my replacement roof.  I started looking for an affordable product that would manage the surplus energy that I produced.  Like others using this site I couldn't find one so I thought to myself if I could develop one (I hasten to add that I haven't  done this on my own, I've developed it in conjuction with a company that has extensive experience of this type of product) that did this not only would my needs be satisfied but I might help some others that were looking for such a product. Before you say, yes I hope to make something extra for myself in the process - but heck what is wrong with that.

If you have a look at the product on my website www.totalpowershop.com it comes with everything you need to monitor and automatically control 2 appliances.  The £299 (yes sorry I rounded it up) pack includes the following:

The control unit
TWO 13 Amp UK 3 pin mains wirelessly controlled sensor sockets
TWO 10mm sensor clamps
ONE data lead
Full operating instructions
Software
ONE UK Mains Adapter for powering the control unit.

!!!!!!!!!!!

Paul Reed's picture

Re: Solar Energy Management

 jollygreengiant - are you intending to contribute to this thread, or is your intention simply to promote your product?

If it's the former - then please provide a worthwhile contribution and welcome to the forum, if the latter, then you may find that your posts are dealt with as spam.

Paul

markbeal2's picture

Re: Solar Energy Management

 Well I don't think that I will be spending £299 for something that seems to be all front and no knickers! Morrisons were selling three wireless 13A socket adaptors simular to them in the pic for less than a fiver. They seem to work fine untill the power goes off then you have to reprogram them with the remote. I think all the guys in here are intrested in controlling power not just switching it.

My unit is running like a dream in the cellar all on it's own, feeding my Immersion heater with most or all of the surplus power available from the PV panels.

My Mk2 is on it's way which will have one more CT monitor on the Immersion heater circuit to sense when the thermostat has switch off on the Immersion heater, then for it to operate another PWM output controlling a small storage heater in the living room.

Anyway... heres to the future and if the electricity supplier wants to monitor my export in the future then good for them. They can shove their 3.1p where the sun don't shine; I would rather have the electricky I generate than to sell it to them for nearly nothing.

Thanks Jolly Green Giant but your device don't seem much use to us power controllers and monitors!

eof's picture

Re: Solar Energy Management

Phil W, using another current transformer just to sense the on/off state of a thermostat looks like overkill.  Why don't you use an opto-isolator, possibly configured as that zero-crossing detector for efficincy?  That's what I would do.

markbeal2's picture

Re: Solar Energy Management

 Thats all very well Phil but it involves more components as oppsosed to another input to the Atmega328 involving a couple of resistors and a cap.

calypso_rae's picture

Re: Solar Energy Management

On a good day, it would be nice if surplus PV power could be routed by the Arduino for a secondary purpose.  This would require it to know when the thermostat on the primary circuit has cut in.

I can see how this situation could be detected by using an extra C/T clamp, but I've yet to comprehend how an opto-isolator or any other practical assembly of hardware could achieve this.  A simple explanation would be most welcome.

As an aside, I've just started a new thread about debugging code which may be of interest to PV routers :)

http://openenergymonitor.org/emon/node/764
 

Robert Wall's picture

Re: Solar Energy Management

Does it matter whether the water heater is absorbing power? I don't think you even care, let alone need to know. If you want to export as the last resort, then surely all that is needed is a list of appliances that can absorb power and you simply attempt to use more of them until all the surplus power has been used. Whether any one comes on or not (or completes its programmed cycle in the case of a washing machine, dishwasher etc) is of no concern. All the controller is interested in is how much power is surplus. If you switch the dishwasher on and there's still surplus power, you switch the washing machine on. If there's still surplus power, then you dump to the immersion heater. If the dishwasher demands more power, you steal it back from the immersion heater. When each completes its program, the surplus naturally increases and you continue to try to dump to the immersion heater. And when that cuts out, you export.

calypso_rae's picture

Re: Solar Energy Management

Robert, I think that most people's systems need to know how much load is connected.  The control system can then calculate what percentage of 'mains on' time should be allocated so as to consume the measured amount of surplus power. 

At present, my surplus power only goes to the immersion.  If the thermostat trips out, the control system works its way up to full power, but no further power can be consumed because the water is already up to temperature.   To the Arduino, however, this situation surely appears no different than when the PV is generating at full power and the immersion is consuming all that it's being given.  How can it distinguish between these two situations?

 

markbeal2's picture

Re: Solar Energy Management

 Well Rae this is my mk two version I am building. I split the Immersion heater from the main consumer unit; that is connected to a Kemo 4kW power controller which in turn is controlled from the Kemo pulse unit from the output of the Atmega328.

Consumer RMS current is deducted from PV RMS current and what is left is for PWM control. The next step I thought of is to use a third CT on the Immersion heater circuit which would used in conjunction with another input on the Atmega. using another output from the Atmega to operate a relay on the pulse controller output. Then using another Kemo power controller on a small storage heater circuit it would divert power to the storage heater when the water heater has switch off.

Every thing would depend on the lovely radiation from that object rarely seen these days but when the fire in the sky is radiating through to my panels then I think that it may be worth doing it.

Phil W said about a zero crossing sensor but at the end of the day for a few more resistors and a cap on my vero board I think the CT would be a lot less hassle and you don't need it to read any accurate readings just to sense when current is flowing or not.

Robert sent me a circuit for a PWM triac controller but I mislaid it, could you send it again Robert please?

Robert Wall's picture

Re: Solar Energy Management

Mark:

I don't think that was me!

markbeal2's picture

Re: Solar Energy Management

 Ok Robert perhaps a senior moment here.

calypso_rae's picture

Re: Solar Energy Management

This all seems to be getting rather confusing:

I understand why Mark is intending to divert surplus power to more than one appliance, and how an extra CT could be used for that purpose.  What I don't follow is how an opto-isolator could be used to sense whether current in the primary circuit is flowing or not.

Powering up such devices in a sequenced manner is important.  It's no good if the storage heater starts to consume power before the DHW gets up to temperature.  And if some DHW were to be drained off, the system needs to recognise when the thermostat kicks in so that power to the primary system can be reinstated.

 

eof's picture

Re: Solar Energy Management

You put an opto-isolator on the connection between the thermostat and the heater.  It doesn't sense current flowing; it senses voltage at the heating element.

Robert Wall's picture

Re: Solar Energy Management

A  C.R.A.F.T   moment, Mark?    Can't Remember A Flipping Thing? 

Robert Wall's picture

Re: Solar Energy Management

Calypso_rae:

This is a new take on an old problem. The principle has been around in the form of maximum demand optimisation for ages - 40+ years to my knowledge. There's bound to be literature about that. In essence, you have a list of loads that you can disconnect to avoid paying a penalty for exceeding demand in any half-hour period (or in your case, connect) and the objective is to prioritise these to achieve the maximum load without passing the limit. Much the same as your desired objective.

If you have multiple switched loads, maybe you need to flip your thinking? Should you be thinking "What loads do I need to disconnect in order to not import power?"

 

 

 

markbeal2's picture

Re: Solar Energy Management

 well the relay would have its contacts connected to the two Kemo power control inputs and the common would to the pwm controller.  Mod the sketch so that when the ct senses no current on the DHW it switches the relay to control the storage heater circuit. If you drain some hot water then the stat switches on again sensed by the CT which switches the relay back to the DHW system. There you are .... NO EXPORT>>>

eof's picture

Re: Solar Energy Management

Small problem with that arrangement: you've removed the power supply to the immersion heater so when the thermostat closes no current will flow!

markbeal2's picture

Re: Solar Energy Management

 Ah... eof correct; back to the drawing board.

calypso_rae's picture

Re: Solar Energy Management

Mark, after powering up your storage heater, can't you continue to supply mains voltage to the immersion?  Then, if/when it starts to draw current again, you can detect this with your c/t and stop feeding the second load. 

eof's picture

Re: Solar Energy Management

You can solve it with one of those zero-crossing detectors (or opto isolator and sweaty resistor) I keep harping on about.  Put it between the common and immersion heater contacts of the relay.  When the relay is switched to the storage heater and the stat is closed, there will be a circuit from live through power controller, zero crossing detector, stat and immersion heater to neutral.  The only fly in the ointment with this is that you can't use it to detect whether or not the stat is closed when you're powering the immersion heater.  If you want to use one detector for both situations, put it across the stat and put a resistor between common and immersion heater contacts which is small enough to activate the zero crossing detector.

eof's picture

Re: Solar Energy Management

Calypso, the problem with having permanent power to the immersion heater is that you will have both of them switched on at once briefly, which may be too much for controller/circuit.

calypso_rae's picture

Re: Solar Energy Management

Hi eof:  My control system, including the device which allocates power to the immersion, is in the garage but the immersion is upstairs in the airing cupboard.  Running a new cable up to the thermostat would be a real pain.  The power cable for the immersion was already nearby so it was easy to connect into this for control purposes.  Using an extra C/T, the presence/absence of current in this existing cable could be easily detected in the garage, so I'm with Mark on this one.

Although not used for anything greater than 3kW, my Carlo Gavazzi controller is rated at 30A.  Two 3kW loads being temporarily on at the same time would not therefore be a problem.  This situation would only occur while the control system works out what to do next, and this process would presumably only take a second or two.

If the Arduino is to determine which load should get the power, there could be two separate AC controllers each fed from a different output pin.  An alternative approach might be to have just one AC controller, but with the Arduino being able to connect/disconnect each individual load from the single controlled supply.

 

markbeal2's picture

Re: Solar Energy Management

 Yes Rae I think thats the only solution, have two controllers fed from different PWM pins, then mods to the software. Problem is my wife keeps using what we are generating with this partial sunshine here. She wonders why the water is not to warm after using washing machine, vaccume and what ever else she may find to switch on!  Telling her that most of the electric is free in the day may have been a mistake. I'm sure some of you guys know what I mean...  don't move wash it, arr little darlings. very difficult to explain about  Watts and things.  But stll.. at the end of the day if you get a tank of luke warm water then it don't take long for the gas to heat it up to temp thereby saving money on gas as well.

Soon for the gas and electric bill to arrive but I'm hoping that the  fual bill has dropped.

fredfred2's picture

Re: Solar Energy Management

I've been looking for a thing that does exactly what you describe. The only systems that I've found so far just switch on when you're above a high threshold, which waste loads of power.

I'm new to this forum, but have been looking to find out who makes this box (pic). The owners of the house weren't in when we were doing some wiring, but this thing controls a standard 3kW immersion heater directly. The panels are only 2kW capacity, so my guess is that some electronics must turn down the mains to the heater element. There is nothing between the box and the immersion heater, which is rated at 3kW.

My guess is that this unit works like a dimmer. When I had put a clamp meter on the in and out cables, the current follow and track precisely. There is a current clamp inside the consumer unit, that must work as a sensor to run the show.

But does anyone know who makes this little unit?

cheers,

fred

 

calypso_rae's picture

Re: Solar Energy Management

Looks a neat solution.  I like the idea of the 90-minute override button.

When my Mk2 design is ready, it would be nice if it could be as compact as this.  It all depends how much power a zero-crossing Triac will actually dissipate ...

Calypso

Robert Wall's picture

Re: Solar Energy Management

"a zero-crossing Triac will actually dissipate ..."

... the rms current  x the voltage dropped across the device in the 'on' state. 

(To size the heat sink? Assume that it is 'on' continuously, and remember of course that the voltage across the triac is essentially constant for the whole half-cycle, at around 1.5 V - but check the data sheet for your particular device).

So likely to be around 20 W for a 3 kW immersion heater load.

Or the same as any other triac for that matter.

Update: 

The 40 A device that Calypso-rae mentions below dissipates 11 W at 12.5 A with a 180° firing angle, according to the data sheet.

markbeal2's picture

Re: Solar Energy Management

 I don'y know if of any use to you but I put my mains bit in an aluminium dicast box which I had laying around. This acts as an heat sink with the Kemo triac unit etc inside. The case is earthed therefore reduces the emf from the triac unit and the electronics is in a seperate plastic box with lcd on the front. bothe are linked with a 9 pin type rs232 lead and associated plugs and sockets on the cases. The di cast box seems to disipate the heat ok as it only gets warm on a good day.

I think if anyone wants to make a controller then perhaps the KEMO products are ideal, CE marked from Germany and easy to use and install. You need a filter with this 4KW control unit but thats soon sorted with some bits of old radio ferrites and some enameld copper wire to make the inductors and some ac caps as well. This goes back to my early days when we used to make dimmer switches and fit them all over the house.. ha ha. 

eof's picture

Re: Solar Energy Management

I mentioned earlier that an SCR has less voltage drop than a triac so if you use a solid-state relay with back-to-back connected SCRs it will dissipate less power.

markbeal2's picture

Re: Solar Energy Management

 Using SCR's and the DC rating of the thermostat contacts needs to be took into consideration. I don't think the standard tank/immersion thermostats will have a DC rating which will be lower than ac rating as they are normally used on AC. It could avoid creating a sauna if the contacts burn together using a triac control!   

eof's picture

Re: Solar Energy Management

You are misunderstanding me.  Two back-to-back SCRs behave like a triac.  I am not suggesting sending half-cycles to the heater, which is both antisocial and I believe illegal.

Also, the thermostat wouldn't care even if being fed with half-cycles: the reason why it is rated more for "AC" than "DC" is because every hundredth of a second the current returns to zero, which extinguishes an arc drawn by slowly-separating contacts.  If you were to feed it with half cycles the arc would be extinguished just as quickly.  DC de-rating is for steady DC, not pulsed DC.

I would be more worried about thermal stress shortening the life of an immersion heater being fed with a regularly changing power as the sun goes in and out and household loads vary.  I wonder if anyone has had a heater fail yet, or if its life is not significantly shortened by this.

Robert Wall's picture

Re: Solar Energy Management

"an SCR has less voltage drop than a triac"

I too thought that was the case, but it seems perhaps it isn't. I've just looked up data sheets for comparable ratings (16 A ) and the forward drops are almost identical - both the threshold voltage and the slope resistance.

"I would be more worried about thermal stress shortening the life of an immersion heater"

Don't many if not most immersion heaters spend their entire life being thermally cycled with a thermostat? My feeling (and I've no data to back it up) would be that you might actually gain on life because a proportion of thermostat switching operations will not now take place, or they will take place at less than full power. The optimum condition - from the heating element's point of view - is when the hot water use is exactly balanced by the power dumped into it, so the thermostat is never required to switch. I can't see that the much slower changes (than the mechanical switch) due to light variations would have any great effect.

eof's picture

Re: Solar Energy Management

Ah, thanks for the research - maybe the thyristor tutorial is wrong then.

Yes, an immersion heater is being switched off and on by its thermostat, but I'm guessing in a conventional situation that this doesn't happen very often, especially if you're on Economy Seven, where this will probably happen only once a day, the power being absent for most of the time when water is being used.

calypso_rae's picture

Re: Solar Energy Management

Thanks, Robert, for your estimate that a triac passing 3kW is likely to dissipate around 20W max, and also Mark for indicating that your die-cast mounted triac is working well.

I've never experimeted with triacs, and frankly have very little idea what I'm doing.  Paul's video, and various tutorials on the web, have however convinced me that the Arduino can easily control a triac when equipped with a suitable trigger device. 

I've bought a couple of triacs and zero-crossing triggers but have yet to try them out.  The datasheets for my 16A and 40A triac appear fairly impenetrable to me at present, but the one for the trigger datasheet seems easier to comprehand.  Crucially, it provides a standard circuit which I intend to try out in due course.

If anyone more capable than I would like to inspect and interpret the attached datasheets, that would be great ...

fewyatt's picture

Re: Solar Energy Management

I have made many of these proportional controllers and found that 2 immersions quickly failed. The design is now commercially available from www.engensa.com/solar24 if you buy a PV system from them and I have not had any reports of failures from them.

One failure was my own within a couple of days. I put it down to old immersions that were seldom used being in a bad state. So with more intensive use they soon failed. Old immersions are often in a poor state, particularly in hard water areas, (mine was corroded right through the outer casing) thus I always recommend replacing the element and putting the new safer thermostat type in when the controller is installed.

My new immersion has been running for > one year OK and I’d agree that the fact that it runs almost all the time at <<3kW offsets the possible slight reliability degradation due to rapidly fluctuating power. Don’t forget that a boiler has significant maintenance costs too so whichever way you heat your water you need to allow for ongoing maintenance/replacements.

It is a good reason not to buy a stepped controller with a 1 or 2kW element. They could fail quickly due to the rapid full power cycling and are expensive to replace, so the already questionable economics of stepped controllers gets worse when element replacement costs added.

Robert Wall's picture

Re: Solar Energy Management

fewyatt

Can you clarify please, by "proportional controller" do you mean phase controlled and by "stepped controller" do you mean burst fire / whole cycle controlled?

fewyatt's picture

Re: Solar Energy Management

No. "Proportional" means phase controlled or burst fired. "Stepped" means just turning the load fully on when a certain power level is reached. Perhaps "on/off" is a better term than "stepped" although it is possible to have a 2 or more output "on/off" controller, so it is effectively "stepped" as different loads cut in.

Robert Wall's picture

Re: Solar Energy Management

Thanks. I was struggling to understand how a burst fire controller's repetition rate of maybe a second or two, which has to be much less than the thermal time constant of the element, could result in significant stress.

eof's picture

Re: Solar Energy Management

Considering how little metal there is in an immersion heater, spread out and in close thermal contact to water, I imagine the time constant is quite short.  Therefore, and to make sure the meter doesn't register, it is best to use a variable timebase scheme, which gives the shortest pattern possible for the required power - certainly well under a second.

Robert Wall's picture

Re: Solar Energy Management

The metal is surrounded by a porcelain-type material inside the sleeve. Hopefully, this is thermally conductive and electrically insulating, and it does does add to the mass.

I have lying about a 3.3 kW one out of an old washing machine. I put power on it in air for exactly 5 seconds and the surface temperature rose by 45°C from a 21°C ambient.

So agreed, 5 s on followed by 5 s off would undoubtedly stress it. But the present collective wisdom appears to be inclining towards variable length bursts that are just long enough to obtain the required duty cycle, and my considered opinion is this won't apply too much thermal stress.

(If you require 1% accuracy, that implies a 2 second maximum period - and I doubt a heater would notice 1 cycle missing in 100. And to counter the obvious comment, if you want 51% you fire one cycle on, one cycle off for 2 seconds then skip an 'off' cycle. The algorithm has to be a bit clever though to do this).

eof's picture

Re: Solar Energy Management

Ah good - perhaps it's not as bad as I guessed.  Did the temperature rise any higher than 45 degrees above ambient after you removed the power?

Robert Wall's picture

Re: Solar Energy Management

The highest temperature I recorded was 66°C, after I'd removed the power. The setup was - shall we say - hairy so I wasn't touching it until there was a clear air gap in both poles of the supply! It cooled very slowly after that - it was still about 55°C after a couple of minutes - I didn't record it accurately.

calypso_rae's picture

Re: Solar Energy Management

RW: If you require 1% accuracy, that implies a 2 second maximum period - and I doubt a heater would notice 1 cycle missing in 100. And to counter the obvious comment, if you want 51% you fire one cycle on, one cycle off for 2 seconds then skip an 'off' cycle. The algorithm has to be a bit clever though to do this

Stuart has already provided a comprehensive table of sequences by which power can be dispensed power evenly over a fixed duration window.  That's fine if conditions remain constant, but they seldom do for long.   Fridges and kettles go on & off, and weather conditions change.  Predicting how much surplus power will be available over the next few seconds will never be an exact science.

Although the future is not clear to see, the past is.  By knowing precisely how much energy has been imported or exported during recent seconds, a reliable decision can be made as to whether the dump load can be safely turned on 'now'.  Modern meters appear to allow a 0.001kWh energy window within which energy can flow to and fro without the customer being charged.  If we're near the top of this window, then the load can be safely turned on 'now'; but if we're nearer to the bottom, the load should remain off to allow the energy level (hopefully) to build up again. 

When using an Arduino to distribute individual mains cycles, I think we may do better to thinking "energy" rather than "power".  With a 3kW dump load, every cycle that is on consumes 60W.  Before each cycle is turned on, a decision could in theory be made as to whether there is enough energy 'in the bag' to support that consumption. 

I wonder whether anyone else is thinking along these lines? 

 

Robert Wall's picture

Re: Solar Energy Management

Calypso_rae: I was simply suggesting from the measured results the maximum period that I could envisage would appear to be unlikely to induce large temperature fluctuations in the heating element.

eof's picture

Re: Solar Energy Management

If you're thinking energy instead of power, one cycle consumes 60J, not 60W.

stuart's picture

Re: Solar Energy Management

calypso_rae : I wonder whether anyone else is thinking along these lines?

 

Not really, but I like the idea, originally I was thinking that we needed more granularity that 1%, but I doubt it would make a difference in the real world.

 

 

 

 

calypso_rae's picture

Re: Solar Energy Management

Hi folks, just to tidy up a couple of careless slips of mine :(

@RobertWall:  Although different approaches for Arduino-based power distribution were aired a few pages earlier on this thread, there's no real connection between that topic and the likely stress on immersion heater elements when using burst mode control.  My attempt at a link, posted during a brief window on a borrowed laptop, was therefore not well made.  My apologies.

@eof: Yes, I did indeed mean to say 60J rather than 60W.  Oops!

 

 

Riggers's picture

Re: Solar Energy Management

 Hi Tim,

I (and Im sure many others) need an 'idiots guide'.

Are you able to provide a 'to do' list of what is required and how to do it?

Im good at DIY but being new to electronics, I do need the above to complete this project. There are many PV switches one can buy, but at £160-300 it seems vert expensive to me, espically when the parts are so cheap.

Kind regards Tim,

 

Steve

calypso_rae's picture

Re: Solar Energy Management

Hi Riggers,

Welcome to the forum.  What, exactly, are you wanting to do?

Riggers's picture

Re: Solar Energy Management

 Thank you for getting back to me.

Im trying to 'store' all of the spare electricty from my PV system (rated at 3.4 kw). ABout 50% of the power goes into the grid. I want to use the spare power to heat up the immersion tank (we have four kids, and they use all the hot water!!).

I dont want to spend out on the 'off the shelf' products, as I believe (wth some help and coaching) that I could build it myself. The commersial systems are very expensive - espicially as this is essentially a smart switch.

I have read all the various forums, and there is alot of useful discussion, but I cannot find a 'how to' description of how to complete the switch - and what to buy?

I hope that makes sense?

 

Kind regards - Riggers

eof's picture

Re: Solar Energy Management

Probably because different people have designed different things, and ideas are still under development.

Do you have a separate consumer unit for the PV?  If not, it's unlikely you will find a single wire which carries all the house current and nothing else, so you will need to use a meter tail and get  a sample of the voltage waveform to give you the direction of power flow.  (You could also put one of the cores of the PV feed through the same current transformer as the meter tail, assuming there's physical clearance.  If you get the combination right, the PV current will be subtracted from the meter current to give you the house current.)  The plus side of using a meter tail is that you can build a system with only one current transformer, as you have all the information you need from that and the voltage waveform.

If you use phase angle control then you will need a bulky and expensive filter to comply with emissions regulations.  There is a lot of misunderstanding about this, with people thinking that snubber networks are filters, which they aren't, and that just because they don't get interference on their radios it's ok.

If you use burst firing you will need to make sure your meter doesn't register the larger exchange of energy with the grid as consumption.  One model of meter has been confirmed to be OK.

I wouldn't recommend using a relay, or even two, with different heater powers.  You won't be making the most of your excess power.

Comment viewing options

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