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.

TMS320F280049M: Global Reload

Part Number: TMS320F280049M


Hello, 

I have some question about Global Reload for F280049.

The below is expecting setting sequence for Global Reload. 

<Initial setting>

 GLDCTL.GLD=1     Global Reload Enable
 GLDCTL.GLDMODE=0     CNT_ZERO(Set the timing)
 GLDCTL.OSHTMODE=1  One shot mode Enable
 GLDCFG                           Select the register to be set by global reload.

<for loop>

  After set the PWM register, GLDCTL2.OSHTLD=1

1. In for loop, unless GLDCTL2.OSHTLD = 1 is set, new PWM register setting is not reloaded to Active. Correct?

2. PWM register setting is reloaded immediately just after  GLDCTL2.OSHTLD = 1. Correct?

3. In case of using GLDCTL2.GFRCLD=1, what value should be set to GLDCTL.OSHTMODE?  Is it 1?

 

Regards,

Furuya

  • Hi Furuya,

    Here are the answers to your questions:

    1) That is correct. When Global Load is in one-shot mode, the configured shadow to active loads will not take effect until the next load event after OSHTLD is set.

    2) Not necessarily. The load event is configurable. Take a look at GLDCTL[GLDMODE]. The new settings will take event when the selected event occurs after you set OSHTLD.

    3) In this case, you should set GLDCTL[GLDMODE] = 1111: Load on GLDCTL[GLDFRCLD] write. You should still set the OSHTLD prior to using GLDFRCLD if you are in one-shot mode.

    Regards,
    Kris
  • Hi Kris,

    Thank you for your answer.
    For 3), should I set OSHTLD before GLDFRCLD is set with GLDMODE = 1111?
    I think GLDFRCLD and GLDMODE = 1111 should be set before OSHTLD is set. Please let me know the reason whey I should set OSHTLD before GLDFRCLD is set.

    Regards,
    Furuya
  • Hi Kris,

    Additional question. For the following setting sequence.

    ==========================================================

    <Initial setting>

     GLDCTL.GLD=1     Global Reload Enable

     GLDCTL.GLDMODE=0     CNT_ZERO(Set the timing)

     GLDCTL.OSHTMODE=1  One shot mode Enable

     GLDCFG                           Select the register to be set by global reload.

    <CLA processing>

     After set the PWM register, GLDCTL2.OSHTLD=1

    ============================================================

    If 100kHz switching frequency and 300kHz control loop, CLA processing is done up to 3 times within a SW cycle.

    In this case, CLA set OSHTLD in the first and second CLA processing loop.

    Then if third OSHTLD is not set after the PWM register is set within a SW cycle, the global reload setting cannot be reflected to next PWM switching, I think.

    Do you have any idea or recommended control method to avoid this?

    Regards,

    Furuya

  • Hi Furuya,

    The general purpose of the one shot mode in global reload is that the load only takes effect when you set the OSHTLD bit. This helps prevent boundary conditions. So in other words, after you have calculated all of your updated PWM values and written them to the shadow registers, then you want to set the OSHTLD bit. If your only load mechanism is going to be the GLDFRC though, I'm not sure it makes much of a difference.

    I have a few questions:

    - Why are you choosing GLDFRC as the load method instead of TBCTR = 0 or another periodic event?
    - In your example, is the CLA writing the PWM registers also? What is the CPU doing with the PWM? In other words, why not just have the CLA do everything to prevent having to manage multiple masters interacting?

    Regards,
    Kris
  • Kris-san,

    - Why are you choosing GLDFRC as the load method instead of TBCTR = 0 or another periodic event?
    It is difficult to explain the detail. It is customer's requirement.

    - In your example, is the CLA writing the PWM registers also? What is the CPU doing with the PWM? In other words, why not just have the CLA do everything to prevent having to manage multiple masters interacting?
    CLA is used for the control loop for power topology, and CPU is doing the house keeping task.

    Regards,
    Furuya