This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28069M: Short pulse suppression

Part Number: TMS320F28069M
Other Parts Discussed in Thread: MOTORWARE, TMS320F28069

Hello,

I am trying to implement short-pulse suppression for an inverter running motorware 18 on a TMS320F28069.

The solution I came up with is to modify the HAL_writePwmData function in the following way:

static inline void HAL_writePwmData(HAL_Handle handle,CTRL_PwmData_t *pPwmData)
{
uint_least8_t cnt;
HAL_Obj *obj = (HAL_Obj *)handle;
PWM_Obj *pwm;
_iq period;
_iq pwmData_neg;
_iq pwmData_sat;
_iq pwmData_sat_dc;
_iq value;
uint16_t value_sat;

for(cnt=0;cnt<3;cnt++)
{
pwm = (PWM_Obj *)obj->pwmHandle[cnt];
period = (_iq)pwm->TBPRD;
pwmData_neg = _IQmpy(pPwmData->Tabc.value[cnt],_IQ(-1.0));
pwmData_sat = _IQsat(pwmData_neg,_IQ(0.5),_IQ(-0.5));
pwmData_sat_dc = pwmData_sat + _IQ(0.5);

// Short-pulse suppression. For min_pulse = 0.056, pulses smaller than 1us would be suppressed
if(pwmData_sat_dc > _IQ(1 - MIN_PULSE_WIDTH)) pwmData_sat_dc = _IQ(1.0);
if(pwmData_sat_dc < _IQ(MIN_PULSE_WIDTH)) pwmData_sat_dc = _IQ(0.0);
value = _IQmpy(pwmData_sat_dc, period);

value_sat = (uint16_t)_IQsat(value, period, _IQ(0.0));
// write the PWM data

PWM_write_CmpA(obj->pwmHandle[cnt],value_sat);
}

return;
} // end of HAL_writePwmData() function

So that too short pulses are rounded down to 0 and too large pulses are rounded up to 1. By testing I came up with the value 0.056 to suppress pulses smaller than 1usecond (switching at 14kHz).

I just wanted to know you opinion about this implementation and its possible effects on the controller or things like overmodulation (which is active).

I had seen a post with a different implementation by saturating the pulses to a min and max values by:

value_sat = (uint16_t)_IQsat(value, _IQ(max_value), _IQ(min_value));

But I would think this solution has 2 problems.

1. It would affect overmodulation since you are limiting the maximum pwm duty cycle

2. It implies higher losses than the previous solution since on the previous solution if you round the duty cycle to 0 or 1, on that cycle that IGBT wouldn't switch and thus increasing efficiency at high and low pwm duty cycles.

Am I missing something? Is there a chance this implementation might be troublesome for some reason?

Thanks in advance,

  • In theory, this would work, but not with overmodulation. Overmodulation sets the value after this API call, so your method would be invalidated anyway. In practice, I don't think you need to do this as deadband will remove the minimum pulse width, making this method extraneous in practice

    Sean
  • I think I don't understand the answer. This is the last function call when the duty cycle is set for the pwm peripheral so overmodulation I would think it should be called earlier (I guess in the CTRL_run). Also I don't think that the deadband removes the short-pulses, I've been able to create pulses of hundreads of nanoseconds even when I have the deadband set to 3 microseconds. The deadband does leave a 3us gap at both sides of the pulse but you can make the pulse as small as you want (or I have something setup wrong).
  • Sorry, I see your code is added in HAL_writePwmData() which is indeed after SVGENCURRENT_compPwmData() so it will supersede the PWM as set by the overmodulation function. I misunderstood the initial post.

    For the code you've added, it should be ok since you are limiting the ON pulse. Overmodulation is only affected by the width of the off-pulse when the low side shunt is sampled. As long as you maintain the minimum OFF pulse width for the low side shunt to be sampled then you should not see any issue with the code you've added

    Sean
  • I believe that the way I do it I am also limiting the width of the OFF pulse. Since what I am doing is, if the pulse > x, pulse =1. 

    However we are using Hall effect current sensors on the phases not shunts, so I guess it won't be a problem.

    My concern about overmodulation is because, from my understanding, if I am increasing the duty cycle from 95+% to 100% that would artificially increase the total Vs output, wouldnt it? Also I guess it would increase a little bit the current as well since the duty cycle is higher. I worry how those effects might affect the motor/controller.

  • Overmodulation is not necessary when using Hall effect sensors, as it is a method for increasing the PWM output when limited by the effect of measuring low side current shunts. If you are using in-line or Hall effect sensing, then overmodulation no longer makes sense. If you want to increase the Vs beyond the typical limit of the system, you will use field weakening, not overmodulation, which increases Vs by commanding current along the D-axis (which is usually 0 in non-salient motor drive systems)

    Sean
  • I think you are wrong. Using overmodulation you can go from having a perfect sinusoidal waveform output to trapezoidal waveform so that the fundamental Vs is higher and therefore increasing the maximum speed you can achieve without using field weakening at all. All this using in-phase sensors. If you are using low side shunts what you need is current reconstruction which is a completely different thing.
  • Going back over this with my colleagues, I've come to better understand your question. Pulse suppression will change the output current vector angle, as you are effectively increasing an active state for the SVPWM. If the pulse is reasonably small enough, the angle error between the output current vector and the flux vector may be negligible and can be ignored. Overmodulation could lead to an increase in frequency of small pulses that you need to ignore - that said, the issue in control for pulse suppression is the same whether you are using overmodulation or not. If you are noticing a decrease in performance due to the suppressed pulses, you will need to keep track of the duration of the ignored pulses and correct the other phases to maintain the correct active time to drive the current vector correctly per the flux angle feedback

    Sean
  • Thanks for taking you time with this, that makes much more sense. What do you mean with a decrease in performance? Higher ripple current or something like that?

    Also, is there any example project or somewhere I can look at to see how could I correct the timing of the other phases to compensate for the short-pulse suppression?

  • The effect should manifest itself as a small phase shift in the current, and an overall reduction in drive efficiency. I don't believe you should notice any noise on the current output, but you may have some small effect, but most likely negligible

    We do not have any example projects for this type of thing though. You could consider subtracting the the removed pulse time from the other pulse time durations

    Sean
  • Hi Sean,

    I think I will leave my implementation for now and study the negative effects. If the effects are noticeable I might try to implement your suggestion. Thanks.