Using a Cyclone to program a K02

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

Using a Cyclone to program a K02

Jump to solution
976 Views
ghermann
Contributor I

Hi,

We are new to the Kinetis processors. We have been using S08 processors for

quite a while. We use the BDM port for programming and a Cyclone Pro or

using the USB bootloader in the S08JM.

The K02 seems to have many more ways it can be programmed. I'm designing a

circuit and want to have a programming port to use a Multilink Universal or

a Cyclone or just serial. What do you recommend? Is there an example

circuit? We have the K22F evaluation board (FRDM-K22F) but that doesn't

really tell us what we need to know for the hardware.

Thanks,

Gerry Hermann

-


1 Solution
808 Views
BlackNight
NXP Employee
NXP Employee

Hi Gerry,

I have been coming from the S08 and S12 world too :-).

The good thing in the ARM land is that there is no proprietary debug way like BDM, instead SWD/JTAG is used.

Typically a 2x5pin SWD/JTAG connector is used, SWD Debugging with the FRDM-KL25Z Board | MCU on Eclipse .

There is as well a 2x10 pin connector (see Tutorial: Using Single Wire Output SWO with ARM Cortex-M and Eclipse | MCU on Eclipse ) which provides more pins e.g. for trace (Tutorial: Getting ETM Instruction Trace with NXP Kinetis ARM Cortex-M4F | MCU on Eclipse ).

While you could use the FRDM-K22F board with a small hardware modification to debug another board (e.g. see Using FRDM-K64F Board to debug another Kinetis Board | MCU on Eclipse ), I recommend that you invest the money into a P&E Multilink Universal or a Segger J-Link (e.g. BASE): they are faster and electrically better, plus they come with extra tools and capabilities you don't want to miss.

If you need trace (maybe you do) and if you can, design your board with the 2x10 pin connector and have the trace pins routed to the connector. Otherwise use the 5x2 pin connector, and then you can use it either with JTAG or SWD mode, see Using the FRDM-K64F with CodeWarrior | MCU on Eclipse  for the pinout. In most cases SWD is sufficient (most of my boards are using SWD only).

As for the circuit, you might have a look at the FRDM board schematics, or I have pasted the SWD debug port for the tinyK20 board (Production tinyK20 Boards arrived! | MCU on Eclipse ) (schematics on GitHub: mcuoneclipse/tinyK20/Board at master · ErichStyger/mcuoneclipse · GitHub )

pastedImage_726.png

at the minimum for SWD you need:

- 1: 3v3

- 3, 5, 9: GND

- 2: SWD DIO

- 4 SwD CLK

- Reset (with a pull-up to vcc and 100 nF capacitor to GND

(The RX and TX lines above are non-standard: we route a target device UART to two pins on the connector which are usually not used, that way we have a nice USB-to-Serial converter with an an attached converter to the SWD cable on the other side).

A serial bootloader is a nice thing to do field updates. But not something you really can use for debugging.

I hope this helps,

Erich

View solution in original post

2 Replies
809 Views
BlackNight
NXP Employee
NXP Employee

Hi Gerry,

I have been coming from the S08 and S12 world too :-).

The good thing in the ARM land is that there is no proprietary debug way like BDM, instead SWD/JTAG is used.

Typically a 2x5pin SWD/JTAG connector is used, SWD Debugging with the FRDM-KL25Z Board | MCU on Eclipse .

There is as well a 2x10 pin connector (see Tutorial: Using Single Wire Output SWO with ARM Cortex-M and Eclipse | MCU on Eclipse ) which provides more pins e.g. for trace (Tutorial: Getting ETM Instruction Trace with NXP Kinetis ARM Cortex-M4F | MCU on Eclipse ).

While you could use the FRDM-K22F board with a small hardware modification to debug another board (e.g. see Using FRDM-K64F Board to debug another Kinetis Board | MCU on Eclipse ), I recommend that you invest the money into a P&E Multilink Universal or a Segger J-Link (e.g. BASE): they are faster and electrically better, plus they come with extra tools and capabilities you don't want to miss.

If you need trace (maybe you do) and if you can, design your board with the 2x10 pin connector and have the trace pins routed to the connector. Otherwise use the 5x2 pin connector, and then you can use it either with JTAG or SWD mode, see Using the FRDM-K64F with CodeWarrior | MCU on Eclipse  for the pinout. In most cases SWD is sufficient (most of my boards are using SWD only).

As for the circuit, you might have a look at the FRDM board schematics, or I have pasted the SWD debug port for the tinyK20 board (Production tinyK20 Boards arrived! | MCU on Eclipse ) (schematics on GitHub: mcuoneclipse/tinyK20/Board at master · ErichStyger/mcuoneclipse · GitHub )

pastedImage_726.png

at the minimum for SWD you need:

- 1: 3v3

- 3, 5, 9: GND

- 2: SWD DIO

- 4 SwD CLK

- Reset (with a pull-up to vcc and 100 nF capacitor to GND

(The RX and TX lines above are non-standard: we route a target device UART to two pins on the connector which are usually not used, that way we have a nice USB-to-Serial converter with an an attached converter to the SWD cable on the other side).

A serial bootloader is a nice thing to do field updates. But not something you really can use for debugging.

I hope this helps,

Erich

808 Views
ghermann
Contributor I

Thanks Erich. Perfect answer.

0 Kudos
Reply