Hi @Robin_Shen ,
For the OPWFMB mode (variable frequency and variable duty cycle), we require a PWM frequency of 0.5 Hz.
The system clock and ADC clock will both decrease if the EMIOS module frequency is lowered to achieve lower frequency PWM because both have the same source clock (CORE_CLK) (Please refer the attached screenshot).
Is it feasible to switch the EMIOS module's clock source from CORE_CLK? If so, how should it be done?
If we set the CORE_CLK = 20 MHz,
EMIOS_CLK = 20M / 16(Clock Prescaler) = 1.25 MHz
Period [in ticks] = EMIOS_CLK / PWM in Hz
PWM in Hz = EMIOS_CLK / Period [in ticks]
PWM in Hz = 1.25 MHz / 65535 (The maximum value we can set in S32 DS IDE)
PWM in Hz = 19.07 HZ
Thus, we will only obtain a minimum PWM frequency of 19.07 Hz when we use the maximum clock prescaler and period value combinations.
In order to get a PWM frequency of 0.5 Hz in OPWFMB mode, what setups are required?
Best regards,
Hareesh