AnsweredAssumed Answered

About PWM duty control in i.MX6DQ.

Question asked by Keita Nagashima on Jan 6, 2016
Latest reply on Jan 11, 2016 by TomE

Dear All,

 

Hello.

We would like to generate the PWM waveform with square pulse (400kHz & duty 50%).

 

[NG case]

- Duty has broken by using Interrupt FIFO Empty  .

- Because the 5 [usec] delay occurs by the processing of  interrupt FIFO Empty.

 

[OK case]

- Don't use the Interrupt sample FIFO empty (FIE)

- PWM output controls on/off by switching EN bit in PWMCR.

 

[Question]

Is my below understanding right?

When output the fixed frequency & constant duty waveform, to continue to write data in FIFO(PWMSAR) isn't necessary.

One should control simply ON/OFF by the EN bit of PWMCR.

 

 

[Other information (Our steps)]

1. Writes sample data to PWSAR register four times.

2. Doesn't write it to PWSAR register in the FIFO Empty interrupt handler.

3. Write 0x78 to PWMSR.

4. Write the optimal data to PWMPR for 400KHz

5. Write 0x01 to PWMIR.

--> we got the intended output waveform (400kHz & duty 50%)

 

Best Regards,

Keita

Outcomes