KDS 3.2.0 Behavior

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

KDS 3.2.0 Behavior

5,859 Views
richardfox75
Contributor III

I randomly suspend execution of the program being debugged. When I resume

execution, the program breaks at the instruction that was being executed at

the time of the suspend. This is causing me trouble because I am trying to

collect function execution times. I cannot reach the breakpoint which is where

I want to suspend to observe timings, without hitting this temporary breakpoint

which is always applied. It only gets removed by manually removing it. And

then it comes back.I have been using KDS for several months, and this never

happened before.

 

Also, I have been planting breakpoints in a particular file for many weeks. Now

suddenly whenever I attempt to plant a breakpoint, KDS prompts for entering

a "Book Mark". I have not been able to resolve this by performing a clean build.

Changing code in the file, re-compiling, and restarting the program execution

does not fix this. This just all of a sudden happened. For the past week I have

not been able to plant breakpoints in this file. What will resolve this?

Labels (1)
0 Kudos
23 Replies

4,472 Views
kennethtait
Contributor II

Richard,

I see this same behaviour on my setup. It's quite annoying. I did some searching on the net and turned up similar issues with other program environments using the mulitlink. the consensus is that this is a GDB problem and how it interfaces with Eclipse. Even when you remove breakpoints, they sometimes do not go away, so I will bet they are not cleared inside the multilink. The only way I have found around this is to do a terminate and relaunch.

My method to find execution times is to use a port bit and external freq/pulse counter. The debugger will add delays at each step so this won't always be accurate. The release version should be dead on.

It would be interesting to note where breakpoints are actually stored..in GDB, in multilink or in eclicpse xml file...

Ken

0 Kudos

4,472 Views
richardfox75
Contributor III

Ken,

Thanks for the information. Regarding timing, I use spare GPIO bits

which I set and clear throughout the code. I have a Logic Analyzer

connected to the GPIO bit. The Logic Analyzer then gives me the

timing information. I only use the debugger to get a "ball park" number.

I am aware of the debugger overhead.

Your method sounds simpler than mine. However, you need a frequency

meter, which I don't have.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
jorge_a_vazquez
NXP Employee
NXP Employee

Hi Richard Fox

I just receive reply for the case, below is the mail:

We are aware of this issue. The problem is caused by a 2 hardware breakpoint limitation of some KL25 devices and the fact that the temp breakpoints do not get cleared by a CDT layer when the session is restarted/terminated.

We are looking into this report to see if P&E plugin can control removing the breakpoints from the CDT layer or adding support for software breakpoint to resolve a two breakpoint limitation.

In the meantime, as a workaround there are two things that the user can do:

1. Use terminate button and debug button to end and start a new debug session. In this case the temp breakpoints are not being added to the list.

2. Go to breakpoints tab and disable/erase existing breakpoints before doing a session restart.

So, it seems that this is a known issue and they are working to resolve the problem. Hope that this could be resolved as soon as possible. Sorry for the inconveniences that this may cause you.


Jorge Alcala

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

0 Kudos

4,474 Views
richardfox75
Contributor III

Thanks for the information. I have been working around

the issue.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,472 Views
kennethtait
Contributor II

I have encountered the same issue.

Using the terminate and relaunch or remove all terminated sessions seems

to have gotten this under control for now.

By no means use the debug button..it seems to do something else, use the

menu item to start a launch.

Ken

0 Kudos

4,472 Views
richardfox75
Contributor III

Re: - KDS 3.2.0 Behavior

jorge_a_vazquez

to:

Richard Fox

06/30/2016 04:22 PM

Hide Details

0 Kudos

4,474 Views
kennethtait
Contributor II

I have seen this same behaviour with the PE multilink FX. I remove a breakpoint and it never goes away. Dis-connecting the usb, reboot sometimes clears it, but not always. This whole debug scenario needs some major attention to detail IMHO

Ken

0 Kudos

4,474 Views
richardfox75
Contributor III

Ken,

Thanks for your response. One other thing that I am having is

time out messages from GDB which halt execution. Are you

seeing similar time outs?

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,475 Views
kennethtait
Contributor II

Richard,

I'm not seeing timeouts, but what I've found is that starting the

debugger is flawed here in KDS.

Do you have it plugged into a direct USB port or through a hub? I've

seen hub issues before with other tools.

For some reason it doesn't remember which debug configuration you used

last, so if you just hit F11 or the Debug button, this will fail 2nd

time in. You have to specifically choose the configuration, or just

relaunch your last one.

I've also had the gdb backend server die on Linux for no reason, yet the

debugger does not seem to sense this, so a complete bailout is needed to

actually kill the process and restart it.

There is alot of other strange behaviour. If I go to the memory browser,

enter 0x400, I see the flash fine. If I put in 0x3c0 to see the

bootloader config area, I get nothing but ???? I have no reason why it

won't inspect this....

I installed KDS as a user with almost root permission, however it won't

do anything unless I start it as root. No amount of fiddling with

permissions will fix this. Again, I'm sure it's some eclipse or java

crap buried somewhere that wants to write a file it can't.. Why does no

one seem to know what's wrong here..who is maintaining this product?

I suspect most all of these issues are eclipse related. I think the PE

backend is mostly good and have found no real issues with the compiler

or linker.

All in all I've wasted far too much time on the tools not working right

and not being able to trust them. A real productivity drain...

The Kboot v2.0 has more bugs and mistakes than I can list so far....

Sorry for the rant, but this is really eating into my time...

Ken

0 Kudos

4,474 Views
richardfox75
Contributor III

Ken,

Not ranting. I have some of the same issues. I am using

a direct USB connection, and Windows 7 ( all I have!).

I have lost weeks of my time dealing with these tools.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
kennethtait
Contributor II

Well now you've made me feel better! I guess I'm not alone here..

Some of the other people I'm working with are using the codewarrior IDE.

Too expensive to stay with long term.They are staying with the basics,

not excuring too far from the demos. It's taken them over a year to get

2 apps running, and they are not novice programers either. I'm the

pioneer trying to move over to the KDS environment since the local

Freescale guys have indicated to us this will be the future and

supported better...we shall see about that.

If I could just once get an out of the box sample to compile load and

debug I'd be happy, but so far I have not seen this with any Freescale

stuff.

Simple compiler mistakes annoy me to no end....

The app notes gloss over much of the basics (Freescale that is),always

assuming you have experience with the environment.

I like the hardware, but the software has along way to go...IMHO

Ken

0 Kudos

4,474 Views
richardfox75
Contributor III

Ken,

I have CodeWarrior also. I would have used it except the micro

that I am using is not supported. Which is why the use of KDS,

plus the reluctance to purchase software tools when they are

"freely" available.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
kennethtait
Contributor II

Richard,

If you are still having trouble send me the details and I will try to

help. It's a learning curve for both of us

Ken

0 Kudos

4,474 Views
richardfox75
Contributor III

Ken,

I appreciate your offer, and the same for you if you need help.

Right now, aside from the occasional time outs things are

working OK. I am near the end of my project and hope to

never have to use KDS again.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
kennethtait
Contributor II

Sad but I must concur.

The hardware here is very solid, but the cost of software dev here far

outweighs it's usefulness..

Ken

0 Kudos

4,474 Views
jorge_a_vazquez
NXP Employee
NXP Employee

Hi Richard Fox

What message does it give you in the console while you're debugging. It could be a problem with your breakpoints, sometimes there are a big number of breakpoints or there are breakpoints to deleted lines that it gives you "Warning - Not all breakpoints could be written" . I recommend you to remove all the breakpoints and add just necessary breakpoints, you can do it in windows>show views>breakpoints. Please also check this posts as references:

Why all breakpoints show "Multiple markers at this line"?

https://mcuoneclipse.com/2014/10/11/failed-to-debug-with-gdb-breakpoints-or-expressions-on-non-exist...

Please let me know if you have any question.


Have a great day,
Jorge Alcala

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

0 Kudos

4,474 Views
richardfox75
Contributor III

Jorge,

The breakpoint issue happens with only the temporary breakpoint at main().

Whenever I suspend execution, a temporary breakpoint is planted at the

suspend point. These temporary breakpoints are not removed! There are no

error messages of any kind in the console window.

The planting book mark issue has been resolved. Starting the IDE resulted

in a message that a particular file, the one with the book mark issue, did

not

exist. I had to delete the source file from the project and then add it

back.

Now breakpoints can be planted. When the IDE complained about the

missing file, I was able to read the file contents via a text editor

outside the

IDE.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
jorge_a_vazquez
NXP Employee
NXP Employee

Hi Richard Fox

Glad that your bookmark issue has been resolved. About your suspend execution issue, the temporary breakpoints that are planted when you suspend appears in your breakpoints list like this?:

pastedImage_0.png

What interface are you using to debug?


Have a great day,
Jorge Alcala

0 Kudos

4,474 Views
richardfox75
Contributor III

Jorge,

I didn't receive a breakpoint picture.

I am using a P&E MultiLink FX.

Dick Fox

Firmware Engineer

NATIONAL CONTROLS CORPORATION BUSINESS UNIT

INSTRUMENTATION AND SPECIALTY CONTROLS DIVISION

1725 Western Dr | West Chicago, IL 60185 | http://www.ametekncc.com

Phone: (630)621-3118 | email: Dick Fox@ametek.com

0 Kudos

4,474 Views
jorge_a_vazquez
NXP Employee
NXP Employee

Hi Richard Fox

The community link to your post is:KDS 3.2.0 Behavior​ you should be able to see the breakpoint picture. While you are debugging you can go to windows>show views>Breakpoints, it should show your breakpoints list, what are the breakpoints that are listed here? they appear with an address and type: temporary?

Best Regards

Jorge Alcala

0 Kudos