Hi Champ,
I am asking for my customer, checking on the epwm configuration (in up-down mode) to trigger ADC SOC event timing.
My customer wants to routinely update the ADC SOC event trigger timing with CMPC for EPWM_SOC_A and CMPD for EPWM_SOC_B, and calculate the new value for CMPC and CMPD every time in a control loop.
Checking with the configuration with the expert, we are thinking to configure the function of
EPWM_setADCTriggerSource(EPWMx_BASE, EPWM_SOC_A, EPWM_SOC_TBCTR_U_CMPC) &
EPWM_setADCTriggerSource(EPWMx_BASE, EPWM_SOC_B, EPWM_SOC_TBCTR_U_CMPD) &
Besides, using the simultaneous write for both CMPC and CMPD at the same time, and global load when CTR=ZERO, to accomplish varied ADC SOC event trigger points with CMPC and CMPD separately.
Is there any configuration that we are missing or we need to think about any scenario to add more code here ?
Thanks and regards,
Johnny