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.

TMS320F2800157: One Shot load execution status

Part Number: TMS320F2800157

Hi,

Problem Statement: Overlap occurs between PWM 1A & 3B or 1B & 3A at randomly as shown in waveform below.

Yellow:- PWM1A, Blue: PWM1B, Pink: PWM3A,  Green:- PWM3B

Configuration details

-> We are using One shot load mode for PWM duty & dead band register update at PWM counter = 0. 

-> Here PWM 1 & PWM 3 counters are in sync however PWM 1 is used for Primary pulses and PWM3 is used for Sync rectification. Normal waveform are as shown below.

Yellow:- PWM1A, Blue: PWM1B, Pink: PWM3A,  Green:- PWM3B

-> On PWM1 & PWM3 dead band module is activated and updated at every cycle based on control loop requirement.

-> The control loop execution is asynchronous to PWM counter.

-> Hence although loading event is known, loading status is unknown. 

-> Is there any provision to understand if the One Shot load is executed, so that next PWM shadow register update can be only executed if checking the status.

-> e.g. if Clear bit status is known in OSTLATCH, execution status can be known.

  • Hello,

    Apologies, but I'm uncertain what you mean. One-Shot mode requires a manual reset of the one-shot latch via the GLDCTL2[OSHTLD] register, therefore it is always known whether or not a strobe pulse has passed- if you have written a 1 to GLDCTL2[OSHTLD], then a strobe is pulsed at the next event.

    Why is it believed that the one-shot functionality is resulting in this behavior?

    Additionally, do ePWM1 and 3 have different DB calculations?

    Regards,
    Jason Osborn

  • Hi Jason,

    One-Shot mode requires a manual reset of the one-shot latch via the GLDCTL2[OSHTLD] register, therefore it is always known whether or not a strobe pulse has passed- if you have written a 1 to GLDCTL2[OSHTLD], then a strobe is pulsed at the next event.

    Following description given in TRM, indicates Latch clears when load strobe occurs and the logic diagram also shows it is automatic.

    Why is it believed that the one-shot functionality is resulting in this behavior?

     Configuration is selected to ensure normal functionality, however overlap is happening randomly which is not expected.

    Additionally, do ePWM1 and 3 have different DB calculations?

    The dead band value remains same however to ensure the constant deadband, values in the dead band registers are simultaneously compensated as per the values in the Compare registers to ensure. Hence values in deadband and compare registers are changing at every cycle if required.

    Pl. lets me know if you need additional information.

  • Hello,

    GLDCTL2[OSHTLD] = 1 allows exactly 1 load event to occur, after which no more events can occur until and unless GLDCTL2[OSHTLD] is set again- hence the name 'one-shot'. Therefore, when OSHTLD is set, the next load event (chosen by GLDCTL[GLDMODE] will propagate.

    You mention that the control loop is asynchronous to the ePWM- is it faster, slower, or merely offset compared to an ePWM period?

    I asked about the DB values because the deadband in the waveform posted above is not the same between ePWM1 & 3- I believe that the issue is in either the calculation of the DB values or the timing of the DB update.

    Regards,
    Jason Osborn