Hi,
I'm working with the IMXRT1176 and would like to implement frequency modulation with the pwm driver. I've had a look at the SDK example and it seems the driver is written with the intention of setting up the frequency on initialization and the performing duty cycle modulation after that. Is it possible to implement frequency modulation with this peripheral?
Thanks
Hi,
Thank you so much for your interest in our products and for using our community.
The driver for the PWM only allows updating the PWM signal duty cycle of a particular PWM channel. And I can't find documentation about PFM with this driver, you would be the first person to do it with the eFlexPWM module. If you succeed, I appreciate your comments about it.
However, the application note AN12713 Generating PWM and PFM by Using FlexIO illustrates how to do what you are looking for but with the FlexIO module and even comes with its respective associated file AN12713SW. It is based on the i.MX RT1010 EVK board but it can easily enable on other i.MX RT Series EVK board.
Hope it helps you.
Have a nice day!
Hi,
Thank you for the reply.
I was able to modulate the frequency by running the PWM edge aligned and then updating the VAL registers with calculated period length and pulse width. To increase resolution, depending on the range, the clock prescaler could be updated. Seeing as the registered were buffered, I didn't encounter any issues when updating them.
Thank you,
Rory