Exact Place at which my application goes weird

Feb 06, 2007 6 Replies

Hi, My application goes into a Deadlock condition OR some_Unknown_Problem. If i use JTAG and do 'Connect' , can i get the exact place of problem OR atleast near to the place of problem ? Any other ideas ?? I Use CCS(Code Composer Studio) & OMAP.



Thx in advans, Karthik Balaguru



Op Tue, 06 Feb 2007 14:42:27 +0100 schreef karthikbg :

It's possible.

That's less unlikely.

  • use your high-level debugger
  • design for testability
  • don't design a system that can deadlock
  • eliminate the possibility or likelihood of some_Unknown_Problem

Gemaakt met Opera's revolutionaire e-mailprogramma: http://www.opera.com/mail/

Fine. Thx for your ideas.

My VxWorks application goes into Deadlock condition. How to View/Identify Reason for Deadlock using VxWorks ? I would like to know a built-in feature in Vxworks that will help in identifying the Deadlock condition and tell me the reasons for the Deadlock .

I do not want to use this programming approach for finding the reason for Deadlock.

Is there any Feature in Vxworks for identifying the deadlock reason ? I do not find any info for Finding the Reason for Deadlock using VxWorks. I use PowerPC. Kindly provide me some solution for this .

Thx in advans, Karthik Balaguru

Do you have a serial port avaiable? You could output a message of some sort whenever an important event takes place. It will slow down your system though unless you just dump all the messages into a big buffer for slow output. Of course this will probably overflow and give you a fresh crash but such is life.

Your JTAG links might enable you to step-through the code and examine registers and other things. Mine will give me a call history so I can see what functions have been called to get me to where I am.

It all depends on how your program is laid out really. If everything is called from one scheduler function then that is a good place for debug code but if you are relying on VxWorks to define your architecture then things are a bit harder.

Basically, you need to think of a method that alerts you when something important happens - a new task, deleting a task, a request for a resource etc - and you need to watch for it getting stuck. This could utilise a debugger, a serial terminal, flashing LEDs or a myriad of other methods.

How do you know it is a deadlock and not an infinite loop or other issue? I believe VxWorks has a facility to view the current tasks and their status. I don't remember how this is done (it has been over 10 years) but it should tell you what they are doing and if they are waiting for a resource, what that resource is.

You should be able to program up a simple status indicator by adding a process to monitor the other processes. We used to do that as part of a watchdog function. But if you don't want to do any programming, you need to learn about the VxWorks tools.

When everything else fails, you can still write some number to a hard coded memory location, reboot, and print its value to see how far you got :-)

That's what I meant with 'high-level debugger'. However, I'm not familiar with VxWorks.

Why not? In the absence of suitable host-level tools, it is a very viable approach.

Gemaakt met Opera's revolutionaire e-mailprogramma: http://www.opera.com/mail/

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required