Author Topic: Classic Aux 2 PWM configuration options  (Read 127 times)

TimBandTech

  • Newby
  • *
  • Posts: 7
Classic Aux 2 PWM configuration options
« on: October 04, 2018, 10:40:03 AM »
I've been trying to understand the second option in the PWM configuration of Aux 2 in "Waste Not Hi" mode.
The descriptions of this figure, which is a choice of { 1, 2, 3, 4, 5 } as a width in volts make no sense.
As I understand it in a voltage regulation situation(charge controller) a PWM output will vary the duty cycle of a resistive load from zero percent up to one hundred percent.
Due to the MPPT tracking the controller can sense when excess power is available and adjust the PWM.
Unlike ordinary diversion controllers the load does not need to exceed the input power and there is no danger of burning up a battery bank should the load fail.
It seems to me that this one to five figure has to do with timing, but I can't get a clean description from tech support.
Is anyone here in the electronics section able to clarify? The manual does not discuss this figure as far as I can tell.
It seems to me that the 'V' on the interface after this figure is a bug. 

IMO this is an excellent offgrid feature that Midnite Solar has that next to noone else has. Sadly it goes misunderstood within the manual and within tech support.
 
Now getting technical on this: If a PWM counter has sixteen bits this means that a gradation of roughly 65 thousandths is available in terms of duty cycle. Given that the PWM frequency is 500 Hertz ( from tech support; not in the manual yet) adjusting the PWM one gradation at a time would take over 2 minutes to vary the duty cycle completely. Thus the need for a more complicated algorithm, which is fed this one to five figure. This algorithm could get quite a bit more complicated, such as  PID type algorithm, and is further complexified by the MPPT feature, which it obviously has to work with. Likely some overshoot and undershoot will be experienced when things are running properly. But you see this discussion is entirely in terms of timing. This is the sensible context to be discussing PWM voltage regulation in terms of. As I see it the language in use attempts to harken back to the Aux 1 style drive which corrupts proper understanding of the PWM system. The PWM system is far superior in terms of caring for the battery bank AND maximizing power delivered to the diversion load. At least it should be.


boB

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2788
Re: Classic Aux 2 PWM configuration options
« Reply #1 on: October 04, 2018, 04:00:37 PM »

PWM operation on Aux 2 goes from 100% off to 100% on over the width in volts chosen.

When the mode's source voltage (usually battery or PV input) reaches the starting threshold,
the PWM will be fully on or fully off depending on whether it is an active high or active low mode.

In 1V width, every 0.1 volt change of that source will cause the PWM to advance in duty cycle
by 10 percent.  So over that 1 volt width, the PWM will widen a little bit.  This is the highest
resolution of PWM that is allowed then because of the voltage resolution of the A/D converter
and resistor divider network used.

When you change to 2 volt width, the range will be 2 volts and the PWM frequency will be lower as
I remember it.

Typically the 1V width should work for everything and the 2,3,4,5 volt widths are only there for versatility
but maybe they shouldn't have been added at all ?  It probably causes more confusion that added benefit
for a lot of users.

There is also a bit more complexity when you take into account one other mode which is DC vs. AC PWM.
In the Aux2 "Clipper" menu you will find this selection.  It should normally be set to AC which will change
the PWM modes of AUX2 to 500 Hz PWM for the 1V width.

For DC clippers, the frequency has to be dropped significantly to around 20 Hz and the width will automatically
be widened.  Unfortunately the only place to adjust the mode for AC or DC is in that Clipper adjustment menu.

So, width is just the voltage over which the PWM goes from full off to full on.

boB
K7IQ

TimBandTech

  • Newby
  • *
  • Posts: 7
Re: Classic Aux 2 PWM configuration options
« Reply #2 on: October 05, 2018, 09:13:46 PM »
Thanks Bob for the reply.

The concept of a 5 volt width specification, or even just a one volt width specification is meaningless as far as I can tell. The charge controller is already in absorbtion mode typically when the diversion load kicks in. (there is no excess power available in bulk mode on most PV offgrid systems.) At least this is the way that it should work; holding that battery voltage within the hysteresis that is the first voltage spec'd in the Waste Not Hi mode. It is already regulating the battery voltage to a tenth of a volt. There will never be a one volt change let alone a five volt change. Such voltage shifts would be deeply disturbing to witness coming out of a professionally built charge controller. Maybe I am misunderstanding what voltage exactly is being addressed. Is this language treating the heating element voltage as a signal voltage? If so that could explain my own disconnect to the terminology, but it should be stated very clearly what this 1,2,3,4,5 specification is. Certainly it is not the battery voltage.

A PWM algorithm insisting on 10 percent duty cycle steps is a misnomer in my opinion. If this is really what Midnite Solar has done then I will be gravely disappointed. I suggest to you Bob that some misinformation was passed down and that the brains that built the Waste Not Hi feature are long gone.  I am going to find out experimentally what is going on and will have to continue to carry my oscilloscope around with me to do it. I've got the Aux 2 out available as testpoints on the wall through a 10k resistor so that nobody can backfeed it. I've got to have some feedback to the owner as to how much diversion he is getting, as it is apparently not logged on the midnite solar charge controller.

What you say about a clipper config spec and an AC versus DC option there is completely foreign to me and is not in the manual within the Waste Not Hi mode. I see that is for wind turbines so I hope I can disregard that. I suppose I could go into clipper mode on the AUX 2 port, change that parameter to AC, then go over to Waste Not Hi mode, but if that matters then I'll be feeling really down.

The pulse width modulation is likely coming off of the LPC2xxxxxxx chip, which is an ARM chip (made by NXP ;was Phillips semiconductor) that has  32 bit PWM counters. Depending on the clock speed this sets a fine scale increment far beyond ten percent duty cycle steps.   The AtoD that you speak of is just the battery voltage right? On a 10 bit converter at 100 Volts max that is a resolution of a tenth of a volt. This is commensurate with resolution of most configuration parameter voltages, and 10 bits happens to be what the ADC on LPC2xxx chips is too. The proper algorithm Bob will adjust the duty cycle of the diversion load gradually rather than abruptly. At 500 Hertz the duty cycle could ramp 10 percent steps in 1/50th of a second. This is way too fast to bother with. I would think that they would be at around a second or maybe a tenth of a second even. Anyway this linear guessing game goes away with a more complex algorithm that has an acceleration built into it. I really do not believe that our 3000 watt diversion load should be stuck at 300 watt intervals of duty cycle; not on a modern PWM system.

I really wish that the language made sense to me. I have a BSEE and understand switched power electronics fairly well. The incredibly efficiencies that we see on modern power electronics are due to the low switching resistance of power MOSFETs, and in high voltage applications IGBTs. The modern On Resistance of a MOSFET could be in the single milliohms in comparison to old BJT days where that could be a VCE sat of a half volt. Less heat is better. Less heat is more efficient. The Classics are running hot at this installation and I doubt that we are seeing the 98 percent figure that they list. The old MPPT-60 were passively cooled and stayed cool to the touch or were barely warm.  I was offsite today; the first full sun day we've had at this installation and the diversion system was not working. I'm about to  lose my credibility on this and it does not feel good. I am really starting to feel like a loser.


TimBandTech

  • Newby
  • *
  • Posts: 7
Re: Classic Aux 2 PWM configuration options
« Reply #3 on: October 06, 2018, 07:49:13 AM »
Ahhh. Is the voltage 'width' that of the PV array?

This figure then is specing interaction with the MPPT algorithm.
This could make sense. Also at say 90 Volts operating voltage the knee of MPPT could fit this range of 1 to five volts and the coarseness of the figure starts to make sense.

I must still insist that the terminology of 'width in volts' is meaningless. Width in time is completely sensible, which carries a direct translation to duty cycle. Hysteresis is a bit tricky to clarify, but it is used to stabilize switched systems by allowing a small error so that rather than oscillate at a high frequency they run at a more sensible lower frequency which is more efficient.

Ahh. So now a PV engineer working off of the MPPT algorithm is focused on I and V curves like these:

which then cause the usage of language such as 'width in volts' which from the PWM side of things is terrible terminology.
This could explain my own misunderstanding... if I am correct.

I believe and possibly will prove that the second configuration figure in Waste Not Hi mode has to do with the MPPT tracking algorithm. This is a very reasonable hypothesis.



boB

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2788
Re: Classic Aux 2 PWM configuration options
« Reply #4 on: October 06, 2018, 02:15:53 PM »

If you are more comfortable with width in time, ( i.e. attack and release time),
but with very small required voltage, down to 0.1 volt, try Aux 1 instead of Aux 2

K7IQ

boB

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2788
Re: Classic Aux 2 PWM configuration options
« Reply #5 on: October 06, 2018, 06:43:12 PM »

The Classic manual does not explain the operation of this Aux 2 PWM method well, if at all.  We will try to fix that real soon now based on your input too.  In this case, the AC/DC mode and width etc. really needs more explanation.

For DC dump loads and Waste Not use, it should be set to AC (the default I believe) which is about 500 Hz.  This should work for AC or DC Solid State Relay (SSRs).  The only reason we have a DC mode and lower frequency operation is for our Clipper that uses the PV input voltage to run the PWM.  Waste Not uses battery voltage.  Power resistors can be very inductive and in the case of our Clipper, 500 Hz requires a large snubber.


Correct too, in that there is no extra power in Bulk MPPT. Have to wait until in Absorb or Float or EQ to use waste not in either Aux 1 or Aux 2.

If you have 3000 watts of dump load, you will not necessarily be able to use all of that.  It can only use whatever is required to keep the absorb voltage from rising above the PWM threshold voltage relative to the voltage regulation set point.  Relative to battery temperature compensated voltage actually.

The voltage regulation set-point  for the battery bank is typically not an exact voltage requiring a 0.1 +/- 0.1 volt accuracy.  If it were, then this mode would have a much less chance of being able to work.   A 48V battery bank will work better than a 24V bank which will work better than a 12V bank due to that accuracy.

There will have to be some voltage buffer...

The actual set point voltages, Absorb, Float or EQ will have to be set slightly artificially high so that the Waste Not set point can operate before that set point voltage comes into play.  The Classic's Absorb, Float and EQ voltage will then be the "fail safe" voltage in case the Waste Not dump load becomes dead or water becomes hot or whatever.  When the charge stage comes out of Bulk and into Absorb (or Float MPPT into Float, etc) then the Waste Not or Diversion can be the method of voltage regulation for that battery voltage set point.

The Absorb timer is enabled by default in the TWEAKS menu so that when the dump load is operating via Aux2, the timer will run and it will finish the Absorb or EQ cycle when dump load has been regulating the voltage.  This is necessary because the actual Absorb voltage is set higher and won't be met like normally when not using the extra energy...   That higher voltage setting is not really desirable but shouldn't be so high as to hurt the batteries as long as the dump load and SSR doesn't die for too long a time.  In a 24V or 48V system, it probably doesn't hurt to run the voltage higher for quite a long time.  12V is a bit tighter requirements. 


The 1V width can start slightly above the voltage which it starts to go into voltage regulation mode as the battery starts its time in Absorb, Float or EQ.
If you have a 3000 watt dump load and you only have 300 watts extra to keep the voltage constant, then the PWM will be at some point just above the cut-in PWM voltage (the lower end of the width V).  As the battery gets more full, it should take less power to keep that voltage at the set-point and there will hopefully be more power available for the dump load and the PWM should widen out a little bit.

The PWM regulation time should be fairly fast too.  Too slow and the Absorb, Float or EQ set point voltages will reduce the power so fast that the dump load won't have time to react.  For Aux 1, there is an adjustable Delay (attack) time if you want a slower response time.  Aux 1 also has an adjustable Hold time (release).  That is hysteresis time if you like.  There is also a High and Low voltage setting but these 2 set points can be as close as 0.1 volts if wanted.

..........................

As for the 98% efficiency figure, we do not publish efficiency numbers for the Classic although some measurements were taken a long time ago.  Not sure where the 98% came from ? It's not easy to measure accurate efficiencies either.  There are hot and cold numbers. input voltages and output voltage and power, making measurable differences as well as unit to unit variations and instrumentation and shunt issues.  i.e. those numbers can vary quite a bit.  Some try to use the meters on the Classic for this.  Not a good idea.  Nice, and expensive Yokogawa power meters and automated measurements are a good way to go along with extremely well matched shunts.

Yes, the Classic gets hot when processing a lot of power throughput.  But, even if it is operating at 98%, it could get hot.  Say it is putting out 3000 watts and is 98% efficient.  That would be around 60 watts dissipated in the Classic.  That is a large amount of power for such a small unit.  The XW  MPPT-60 has a large-ish heat sink (and no fan), so heat is going to be distributed over a larger area as well as having a lower output current and input voltage rating.  We could make it a bit more efficient but would take more space and cost more.  We are working to improve efficiency or at least have larger heat sinks in future products.  They will cost more, partly because of more expensive parts and partly from tariffs that some of the parts cost now.

boB
K7IQ

TimBandTech

  • Newby
  • *
  • Posts: 7
Re: Classic Aux 2 PWM configuration options
« Reply #6 on: October 11, 2018, 11:04:19 AM »
Bob, thank you for the detailed response.
I had my first sunny day onsite yesterday.
I could not get the diversion working, including some of the tricks that you mentioned.
I tried giving the diverting classic a slightly higher battery voltage via the calibration offset, thus tricking into thinking it has excess power.
I eventually tried all sorts of things to no avail. I went away thinking that this feature is vaporware.
Doing some other work it crossed my mind: what if there is a sign error in the manual?
So I went back and changed the -0.2 Volt figure (the first configuration option which incidentally defaults to a high positive value) to a positive value.
Upon coming up to +0.5 Volts the algorithm did indeed kick in, and did lift the power harvest to over 3kW at the tail end of a good day of absorption, though we've had quite a bit of cloudy weather lately.
We have about 7kW of panel in three arrays, and just 3kW of heating element to divert into.
At the end of the day I did see that the PWM algorithm quit, which is reassuring.

Now I can say that I've gotten the system working but that also I no longer understand the meaning of either of the configuration options.

I think whoever wrote the manual is thinking in terms of how this feature ought to work, which is how we all must think of it. However the engineer that got it to work correctly likely had to come at it from a different angle. Consider that the charge controller already runs a clean charge control algorithm. Why break that algorithm for the sake of this diversion functionality when the signal of excess power is coming from the MPPT side? Yes, we are consuming it at the battery bank side, but really it doesn't matter where we take it from, so long as we stop taking it when there is no longer excess power(or ramp it down, as a good algorithm should). It may come off of the inverter, or even directly off of the PV array. These options are sensible in that these are high voltage sources. That is speculative, but a good engineer would likely go there while seeking the general solution. 

The best means of communication is not to squeeze the context of the algorithm into some old jargon such as a traditional diverter running at low voltage on relays.
The best would be to completely expose the algorithm and the meaning of these numbers. We are dealing here with logic in firmware. These numbers do actually mean something.
At this point I have to completely disregard the manual. For instance the graph in the manual is inaccurate; if it were accurate it would demonstrate the duty cycle increase in the intermediate zone(instead each wave is 50% duty cycle). The first parameter is inaccurately described, while the second is not described at all.

This is not a hot rod. This is not a guessing game. Oh, yes it is. Possibly the manual is correct and there is a bug in the firmware. I feel that I know less now than when I opened this thread.

 - Tim
   AB1AH


ClassicCrazy

  • Hero Member
  • *****
  • Posts: 1860
Re: Classic Aux 2 PWM configuration options
« Reply #7 on: October 11, 2018, 08:19:55 PM »
Tim ,
You may be interested in this discussion .
http://midniteftp.com/forum/index.php?topic=3881.0

Larry
system one
Classic 150 , 5s4p  Kyocera 135watt , 12s Soneil 2v 540amp lead crystal for 24v pack , Outback 3524 inverter
system two
Classic 150 ,5s 135 watt Kyocero , 16s Calb 100AH LiFePO4 , Outback VFX 3648 inverter
system three
Midnite KID MPPT 24 DC in to  12 volt AGM batterie

boB

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2788
Re: Classic Aux 2 PWM configuration options
« Reply #8 on: October 12, 2018, 12:24:41 AM »

I need to look at the manual.   I bet it isn't nearly as good as it could be on this subject.

Thanks for the input.

boB
K7IQ

TimBandTech

  • Newby
  • *
  • Posts: 7
Re: Classic Aux 2 PWM configuration options
« Reply #9 on: October 12, 2018, 10:33:08 AM »

I need to look at the manual.   I bet it isn't nearly as good as it could be on this subject.

Thanks for the input.

boB

OK Bob. Thanks. I've gone back to your first post and see that as you discuss the source you are referring to the PV array, so this explains the problem of explaining this feature to the lay person. On top of the complexity of PWM is the complexity of MPPT, at which point a normal person is going to feel overwhelmed. Unfortunately though there may not be a lay person translation back to unswitched electronics other than to play it as if it is a continuous system, which again would ride the language of duty cycle IMO.

WillEert

  • Full Member
  • ***
  • Posts: 151
Re: Classic Aux 2 PWM configuration options
« Reply #10 on: October 13, 2018, 11:31:23 AM »
I have never been able to get the Aux 2 PWM system to work satisfactorily.

You are correct. If the PWM system worked correctly then the drawing in your previous post does not accurately reflect what would happen. The red curve should be flat , assuming one does not exceed the diversion load.

A PWM diversion system should have one set point - the voltage offset above or below the desired battery voltage that the PWM starts or stops. A PID controller controlling a standard timer manipulating the PWM % on / off time then increases or decreases the PWM rate to control the battery voltage to set point. This control system will always turn the diversion on when needed and also turns it off when required and is very simple to configure. The system I use usually controls the battery voltage within .1 - .2 V of the desired Classic Voltage (depending on charge stage).

My system over arrays the battery bank amps by quite a bit. Sometimes I have excess power during bulk. This power I divert based on amps flowing to the battery bank using a PID PWM control loop using WBJr amps as the control variable (amps above setpoint). This control loop usually controls the amps to the battery within about 1 - 2 amps of setpoint. Love the WBJr.

I love the Classic and the Midnite people. The Aux 2 PWM system does not work as well could however.

Will

(1) 24 ET 185 mono, Classic 150,8x Surrette 6CS25p, 3x Magnum 4448, homecooked diversion system;
(2) 15 Heliene 330 mono, Classic 150; (3) 2 X 6 Hansol 345 mono, 2 stand alone Hotspot ACDC12C Mini-split heat pumps.

boB

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2788
Re: Classic Aux 2 PWM configuration options
« Reply #11 on: October 14, 2018, 09:22:49 PM »
You're right, Will.  Should only be one setting and there should NOT be a PLUS relative setting in that menu.

Since you have been using modbus to communicate with the Classic, have you been remotely operating
Aux 1 or Aux 2 operation using a small computer to sort of do just this ?

As for PWM not working, I'm not sure if you mean the PWM doesn't work at ALL or you don't like the 1.0 volt width  or ?....

The Classic's A/D has a resolution of 0.1 volt so it cannot have any intermediate PWM duty cycle between that.

I suppose there are some tricks that could be done using average voltages that can actually increase the resolution somewhat...

But voltage regulation accuracy doesn't have to be dead-nuts one voltage plus/minus 0.1 volt.  There are variables
that would make an exact figure impossible IMO.

Resources are not infinite either.  That goes for engineers as well as hardware processing.

As for it not being super easy to understand, there can be a lot to learn if one hasn't been working with electronics much.
More explanation and pictures and animations might help though.

boB
K7IQ