New to freescale-Getting started with FRDM-KL46z

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

New to freescale-Getting started with FRDM-KL46z

Jump to solution
Contributor II

Dear Guys,


I am Hesam, who is expert in other types of MCUs but very fresh to Freescale MCUs.

I want to start with Kinetis and i have FFRDM-KL46z board to start with.

I have installed CW 10.5 and know how to create a new project but i have two main problems:

1- what are libraries i can use in CW to for example write a simple blink on gpio?

2-how to generate .srec or hex code(if i should)?

3-How to program the code to the MCU?

the structure of the Kinetis is and CW is tottaaly different with what i have worked before(I have worked with MPLAB(MICROCHIP) CODEVISION(ATMEL),..)

and would appreciate your response to get started.

Thank you very much,



1 Solution
3 Replies
Contributor II

Hi Guys,

@Santiago : Thank you for your complete answer and for the useful blog, i have many thing to do in this week with that blog.

I always believed using automatic code generators and such staffs does not work very well since cannot make much efficient code; at least for other MCUs i have worked with, is it the same for Freescale MCU? what do you think?(sorry i voted your answer as useful; then tried to change my vote to correct answer, but couldnt:smileysilly:. is there anyway to change voting?)

BlackNight: Thanks for your useful link.

0 Kudos
NXP Employee
NXP Employee

Hello Hesam,

Welcome to Freescale MCUs :smileyhappy:.

I think you are going to find very useful the blog of my colleague Erich Styger:

Freescale provides a tool integrated in CodeWarrior called Processor Expert. It is a visual way of configuring each peripheral of the microcontroller, and the tool generates the code for you, so after configuring the peripheral with the visual tool you can examine the code and of course modify or reuse it. It also creates functions to use the peripherals (Get the value from an ADC measurement, send a block of characters from the UART...). It's a really useful tool!

We also have source code examples, you can download the examples for the FRDM-KL46 here:

ID and Description VendorAvailabilityFavorite
KL46_SC: FRDM-KL46Z and TWR-KL46Z48M Sample Code Package.
Size (K): 29476 Format: exe Rev #: 1 Modified: 10/29/2013

If you are interested in processor expert, those are some interesting post from Erich's blog (But he has a lot more!):

MCUs registers watched with Processor Expert

Pins and signals with PEx

How to use PEx components, with examples and descriptions of each function and parameter.