How to program Cortex M0+?

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

How to program Cortex M0+?

1,635 Views
mporra
Contributor I

hello! firstly sorry, but my english is not well...

This is the first time I program ARMs and I'm using a FRDM-KE02Z40M freescale board, and I did a project with that board. Now, I have to make my own board using MKE02Z64VQH4 chip and of course, after I made the new board, I'll have to program the chip... 

My questions are...

To program, do I have to desing or copy the usb port circuit from the freescale board?

Is there any other way to program MKE02Z64VQH4 chip ON BOARD? (using freescale bootloader).

Can I use "threads" with this chip? Which one would you recommend?

I hope you have understood me. Thanks a lot!!!

freescale 

3 Replies

1,330 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi Matias,

    Welcome to use the kinetis E series chip.

   FRDM-KE02 board have the on board debugger, you can find the board also have a K20 chip, that is the on board debugger.

   If you want to design your own KE02 board, you don't need to add the on board debugger, you just need to use the KE02 SWD interface, the use the external debugger, eg: Segger's JLINK or the P&E Micro's Multilink universal.

  You don't need to copy the USB port, I suggest you use the external JLINK or Mutilink to debug your own board.

Wish it helps you!

If you still have question about it, please kindly let me know!

Have a great day,
Kerry

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

1,330 Views
mporra
Contributor I

Hello Kerry, thanks a lot for your answer! 

I was reading that Freescale board has (on-board) some pins (10) as SWD interface to program ke02 without OpenSDA. The User's Manual says "It is possible to isolate the KE02Z MCU from the OpenSDA circuit and use J7 to connect to an off-board MCU." Maybe I can connect the external debugger there...

Okay, if it's okay, I can program ke02 externaly. 

But now, I have 2 new questions:

About external debugger: I live in Argentina and JLINK or Mutilink are very expensive... 

  • Is there any other method to program ke02? by SWD interface... using other board, some chip, I have a board with FTDI FT2232, maybe I can use this board hahah.  

About software: in case I use SWD interface...

  • Can I use freescale bootloader and CodeWarrior ? or Do I have to use any other software? 
  • Can I use threads (like do two programs at the same time) in this ke02z? 

Kerry: thanks thanks thanks a lot for help me. You're the best!!! 

0 Kudos

1,330 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hello Matias,

   Sorry for my later reply, really too busy these days.

   Answer your two questions:

1. About external debugger:

   It seems you already have the FRDM-KE02, it's OK.

   Give you a good news: our FRDM board's on board debugger also can debug the external chip or kinetis board.

   So, just follow me.

1) make the FRDM-KE02 as the external debugger.

  Download the JLINK firmware to your FRDM-KE02 board, just make your board debugger as the JLINK.

  Then check the following picture:

   pastedImage_2.png

Remove the R58, then use J7 to connect to your external SWD interface.

Actually, R58 will determine the on board debugger to connect to the on board chip or the external chip.

If you connect the R58, SWD will connect to the on board KE02 chip.

If you disconnect the R58, SWD can connect to external KE02 chip with J7.

2. About software:

1) Can I use freescale bootloader and CodeWarrior ? or Do I have to use any other software?

If you just want to use the application code, you don't need bootloader.

About the IDE, you can use KDS, CW, MCUXpresso, IAR, MDK.ect.

Abou the sample code, you can use sdk_2.3.0_FRDM-KE02 or the driver, please check these link:

1' KSDK

   Welcome | MCUXpresso SDK Builder 

Choose FRDM-KE02, generate the code and download it.

2' driver code

FRDM-KEXX Driver Library Package

2) Can I use threads (like do two programs at the same time) in this ke02z? 

  Maybe you need to find the programmer, but it's too expensive, more expensive than the JLINK or PE multilink.

Wish it helps you!

If you still have question about it, please kindly let me know!


Have a great day,
Kerry

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

0 Kudos