How to setup SEGGER J-Link lite debugger connection in Kinetis Design Studio 1.1.1

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

How to setup SEGGER J-Link lite debugger connection in Kinetis Design Studio 1.1.1

How to setup SEGGER J-Link lite debugger connection in Kinetis Design Studio 1.1.1

When you want to start debugging with SEGGER J-Link lite debugger in Kinetis Design Studio 1.1.1 you must set properly several options otherwise the debugger behave incorrectly (it seems that debugger works but the application execution does not work - e.g. functions are not called).

 

When you create a new Kinetis Design Studio project (with Processor Expert), write you code and build the application you must also create a debug configuration (open the context menu of the project in the Project Exporer and select Debug As / Debug Configurations...).

In the Debug Configuration window create a new debugger connection for GDB SEGGER J-Link Debugging and set the correct values for the derivative of your project (e.g. MKL25Z128 derivative on FRDM-KL25Z target board):

On the Debugger tab set the device name (see the list of Supported device names)  (e.g.set value MKL25Z128xxx4 for the MKL25Z128) and uncheck the Allocate console for semihosting and SWO (it is not supported).

 

15776_15776.pngpastedImage_4.png

 

On the Startup tab uncheck Enable semihosting and Enable SWO.

 


Click on Apply to save the settings. the debugger is connection is set properly now and you should be able to debug your application (click on the Debug button).


Note: You can use this option for the OpenSDA connection when the SEGGER firmware is flashed. SEGGER offers a firmware running on the Freescale OpenSDA platform which makes OpenSDA compatible to J-Link Lite (see pages https://www.segger.com/opensda.html). You can find more details about OpenSDA MSD Bootloader in the OpenSDA User’s Guide document, see http://www.freescale.com/files/32bit/doc/user_guide/OPENSDAUG.pdf

Labels (1)
Comments

Hi Marek,

I have been using PE Micro USB multilink for debugging my project, but recently I tried j-link segger debugger. I was very impressed with the performance, but one thing I could find in the j link segger debug config settings is, protecting certain part of the flash area while loading a new application.

We have a bootloader running on  the chip and we don't wish to erase that part of the memory when we are developing /debuging the application code. This is achievable using PE Micro debugger settings. Is it also an option with J-Link segger?

Thanks,

Kaustubh

Hi Kaustubh,

by default,  the J-Link will not erase any flash blocks which are not part in your application. So if you download your application with the J-Link, it will not overwrite the bootloader parts if you do not have it included in the binary. I would have to check if the J-Link includes commands for explicit protection (well: exclusion) of memory.

What I have done in the past where the application part had some flash areas in it I wanted to exclude, I used the SRecord utility to get that stripped off.

The SRecord utility is a very powerful utility with a command interface to manipulate binary (not only S-Record) files, see https://mcuoneclipse.com/2015/04/26/crc-checksum-generation-with-srecord-tools-for-gnu-and-eclipse/  and https://mcuoneclipse.com/2016/02/26/merging-s19-files/ .

I hope this helps,

Erich

Thanks for such a quick response Erich. I will look into those blogs and see how I can use in my application further down the road. I am already buying more of J-Link seggers for the rest of the team!!

Kaustubh

No ratings
Version history
Last update:
‎10-17-2014 12:58 AM
Updated by: