how can I increase i.MX6UL PWM clock speed?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how can I increase i.MX6UL PWM clock speed?

943 Views
cbrake
Contributor III

Hi,

I'm working on a project where we'd like to run an i.MX6UL PWM at 1MHz.  Experiments under Linux suggest the clock feeding the PWM is only 24MHz, which gives us a max practical PWM frequency of about 400KHz.

Is there any way to increase the speed of the clock feeding the PWM to 100MHz?  If so, where are these clocks configured in Linux?

Thanks,
Cliff

Labels (2)
Tags (2)
0 Kudos
2 Replies

602 Views
cbrake
Contributor III

I dumped the ipg and per clock rates in the pwm driver, and they both appear to be set to 24MHz:

printk("CLIFF: per clk rate: %i\n", clk_get_rate(imx->clk_per));

printk("CLIFF: ipg clk rate: %i\n", clk_get_rate(imx->clk_ipg));

CLIFF: per clk rate: 24000000
CLIFF: ipg clk rate: 24000000

I suspect re-configuring the per or ipg clocks would likely be a fairly large task as they are likely used for a number of things.

Cliff

0 Kudos

602 Views
igorpadykov
NXP Employee
NXP Employee

Hi Cliff

one can try to use ipg_clk in PWMx_PWMCR, field

CLKSRC. Its max frequency 66MHz described in Table 18-4. System Clock

Frequency Values i.MX6UL RM  http://www.nxp.com/docs/en/reference-manual/IMX6ULRM.pdf 

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos