Can we use the code for K series MCU in the L series MCU?

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

Can we use the code for K series MCU in the L series MCU?

377 Views
pratiekbhadrana
Contributor III

Hello,

We purchased dev boards for the K series MCUs. But now we have decided to use the L series Cortex M0 MCUs. If we consider only the peripherals common to both families, can I test the code on the FRDM K64 and later convert it for use in the KL04?

I am using KDS 3.0.0 with Processor Expert. Not using KSDK.

Thanks

0 Kudos
1 Reply

286 Views
mjbcswitzerland
Specialist V

Hi

It depends on the software that you are using. There are a lot of differences between K and KL families (different peripheals, different clocks, different registers, different Flash) so the code tested on a K64 will not run on a KL part without appropriate adaptation.

It is possibe to write the HAL (hardware application layer) so that applications are compatible but the drivers below the HAL have to be modified in many cases to acheive this. You cannot write and test these drivers on a K64 when they are destined for KL parts. They need to be tested on appropriate KL parts.

Regards

Mark

Kinetis: µTasker Kinetis support

KL03: µTasker FRDM-KL03Z support

KL05: µTasker FRDM-KL05Z support

K64: µTasker Kinetis FRDM-K64F support  / µTasker Kinetis TWR-K64F120M support  / µTasker Kinetis TWR-K65F180M support

For the complete "out-of-the-box" Kinetis experience and faster time to market

0 Kudos