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.

TMS320F2800137: void HAL_setupPWMs

Part Number: TMS320F2800137

Tool/software:

Hello, I am using the official routine
C:\Users\Lenovo\workspace_ccstheia\universal_motorcontrol_lab_f280013x\
If you want to add a function, you can directly change the value of the PWM frequency without going through
The USER_M1-PVNet FREQ_kHz change is mainly used to generate a 50% square wave

Official routines in f28027
AL_setupPwms(halHandle,
(float_t)USER_SYSTEM_FREQ_MHz,
USER_BEE_PERIOD_usec,
USER_NUM_PWM_TICKS_PER_ISR_TICK);
In the function
USER_BEE-PPERIOD_usec and USER_NUM_SPUYL-TICKS-PER_iSR_TICK
Can be directly changed through variables

But the function in f280013
void HAL_setupPWMs(HAL_MTR_Handle handle)
I found that once I call it again, PWM loses its waveform. Why is this

  • Hi,

    You will need to update the PWM TBPRD register during run time and make sure other code is not overwriting it. You can use a DriverLib function for this purpose.

    But the function in f280013
    void HAL_setupPWMs(HAL_MTR_Handle handle)
    I found that once I call it again, PWM loses its waveform. Why is this

    What do you mean by loses its waveform?

    Best,

    Kevin