50 Hz Sine Wave with PWM

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

50 Hz Sine Wave with PWM

1,206 次查看
rogeliovdm
Contributor II

Hi everyone,

I need to produce a 50 Hz sine wave modulated with a PWM at 400 KHz. What I have right now it's FTM0 PWM overflow interruption that loads the next sine value from an array with 8000 samples. The problem with this approach is that is taking up to much time from the micro's CPU. 

My idea is to implement a different solution using DMA, so it loads the sine values without the CPU having to do any actual work. 

My problem is that I can't find any way of doing this from the processor expert (sdk 3.0.0). 

Could you please help me finding the best way to get this? Should I use the DMA? Or is there a way of sticking to the PWM modulation without consuming too much memory? 

Thank you in advance

0 项奖励
回复
3 回复数

1,192 次查看
danielmartynek
NXP TechSupport
NXP TechSupport

Hi Rogelio,

Unfortunately, we don't have any SDK example with DMA - FTM_PWM, but I will send you a non-SKD example that utilizes that.

 

Regards,

Daniel

1,184 次查看
rogeliovdm
Contributor II

Hi Daniel, 

 

I appreciate again your response, but in the email that you sent me there is not a file attached. 

 

Could you re-send it to me with the file in the thing you said please? 

 

Regards, 

 

Rogelio

0 项奖励
回复

1,188 次查看
rogeliovdm
Contributor II

Hi Daniel, 

I've already answered your email. 

 

Thank you so much!

 

Rogelio V

0 项奖励
回复