i.MX6 PWM Polarity

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

i.MX6 PWM Polarity

1,395 Views
ryanerb
Contributor III

I know the DIO on the i.MX6 supports PWM.


The question is, does it support changing the polarity of the PWM?

I attempted to set the polarity and it would not let me ....

root@imx6:~# echo inversed > /sys/class/pwm/pwmchip0/pwm0/polarity

-sh: echo: write error: Function not implemented

From the Linux pages online, it says:

polarity - Changes the polarity of the PWM signal (read/write). Writes to this property only work if the PWM chip supports changing the polarity. The polarity can only be changed if the PWM is not enabled. Value is the string "normal" or "inversed".

Labels (1)
Tags (3)
0 Kudos
3 Replies

1,005 Views
igorpadykov
NXP Employee
NXP Employee

Hi Ryan

according to description in Chapter 51 Pulse Width Modulation (PWM)

i.MX6DQ Reference Manual

http://cache.freescale.com/files/32bit/doc/ref_manual/IMX6DQRM.pdf

polarity can not be changed.

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

0 Kudos

1,005 Views
ryanerb
Contributor III

Hello Igor,

Chapter 51 states on page 4482:

• Active high or active low configured output

I would assume this indicates it does allow for polarity to be changed.

Please clarify and provide a copy/paste from the RM with a page number if possible.

Thank you,
Ryan

0 Kudos

1,005 Views
igorpadykov
NXP Employee
NXP Employee

Hi Ryan

it can be configured with PWMx_PWMCR[POUTC], p.4490,

sorry for overlooking.

Best regards

igor

0 Kudos