Need sample code of FTM for PWM Generation

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

Need sample code of FTM for PWM Generation

Jump to solution
3,334 Views
sujinvincent
Contributor II

Hi All,

I am using Kinetis K26-180M, I am new for embedded system and i need to generate multiple frequency's tone using PWM,

In my hardware the speaker lines are with FTM1 and FTM2 modules, could you please give any sample code for pwm genration on FTM module. also i am using IAR embedded work bench.

Thanks and Regards,

sujin

Labels (1)
0 Kudos
1 Solution
1,662 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi

Maybe you can refer the example in "AN5142 Features of the FlexTimer Module".

AN5142.png

Best Regards,

Robin

 

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

View solution in original post

6 Replies
1,662 Views
mjbcswitzerland
Specialist V
0 Kudos
1,662 Views
sujinvincent
Contributor II

thanks mark

0 Kudos
1,662 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi Sujin,

You can refer the PWM examples in KINETIS-SDK.

FTM PWM SDK_2.1_MK26FN2M0xxx18.png

Please search K26 then select MK26FN2M0xxx18 and download SDK_2.1_MK26FN2M0xxx18.

Select K26.png

Download SDK_2.1_MK26FN2M0xxx18.png
You can getting start with KSDK reading "How to start with KSDK".

 

Best Regards,

Robin

 

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

0 Kudos
1,662 Views
sujinvincent
Contributor II

Hi Robin

thanks for you time

I got those examples, I gone through it, I feel too hard to digest those configurations and coding, Bcoz I am entirely new for embedded system, so if there is any code for accessing from register level it will more helpful to me

my situation is like i need to create bare metal example in which configure the clock as external 16 MHZ oscillator, from that oscillator i need to clock the timer module.

Thanks and Regards,

Sujin Vincent

0 Kudos
1,663 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi

Maybe you can refer the example in "AN5142 Features of the FlexTimer Module".

AN5142.png

Best Regards,

Robin

 

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

1,662 Views
sujinvincent
Contributor II

Thanks Robin

0 Kudos