473,769 Members | 1,748 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Stack Trace

Hi,
Please guide me to the right group(s) if the post isn't on topic here.

My program is running on a ARM7 h/w on top of an RTOS. I want to dump
the names of the functions that were called in the sequence they were
called (stack) onto a file as part of the assert routine. Something
like a core dump in *nix.

How to implement something like this? Where do I need to look?

Regards
Sukrit

Jan 11 '06 #1
3 2268
In comp.arch.embed ded su**********@gm ail.com wrote:
My program is running on a ARM7 h/w on top of an RTOS. I want to dump
the names of the functions that were called in the sequence they were
called (stack) onto a file as part of the assert routine. Something
like a core dump in *nix.
Thats' not very likely a good idea in an embedded system, which won't
typically have anywhere to output this stack dump to in the first
place, nor the symbol tables needed to decode address into names, nor
still be in a state stable enough for the printed dump to be 100%
credible. You should use existing dedicated debugging interface of
the CPU (--> JTAG) and your development system's debugger instead. Or
get a development environment that can do that for you, if your
current one doesn't.

Better still, don't let assert() failures occur, ever, in code far
enough from your desk that your debugging tools can't access it ;-)
How to implement something like this? Where do I need to look?


If you must ask, the answer is unlikely to be of much use to you.
Such information should be part of your RTOS's and/or compiler's
technical documentation, if it's made available at all. If you didn't
guess that by yourself, I'm afraid you're rather clearly in over your
head already.

--
Hans-Bernhard Broeker (br*****@physik .rwth-aachen.de)
Even if all the snow were burnt, ashes would remain.
Jan 11 '06 #2
su**********@gm ail.com writes:
Please guide me to the right group(s) if the post isn't on topic here.

My program is running on a ARM7 h/w on top of an RTOS. I want to dump
the names of the functions that were called in the sequence they were
called (stack) onto a file as part of the assert routine. Something
like a core dump in *nix.

How to implement something like this? Where do I need to look?


This looks appropriate for comp.arch.embed ded; it's off-topic for
comp.lang.c. Followups redirected. (Not that that will do any good
unless everyone responds to this followup.)

--
Keith Thompson (The_Other_Keit h) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
Jan 11 '06 #3
su**********@gm ail.com wrote:
Hi,
Please guide me to the right group(s) if the post isn't on topic here.

My program is running on a ARM7 h/w on top of an RTOS. I want to dump
the names of the functions that were called in the sequence they were
called (stack) onto a file as part of the assert routine. Something
like a core dump in *nix.

How to implement something like this? Where do I need to look?


I suspect that you ill need to supply more information about which RTOS and
what programming environment you are using in order to get the most
appropriate response to this question. Of course, had you been using Forth,
I could have given an answer to this as such things are usually easy for a
Forth based system to do (by several methods).

--
*************** *************** *************** *************** ********
Paul E. Bennett ............... .....<email://pe*@amleth.demo n.co.uk>
Forth based HIDECS Consultancy .....<http://www.amleth.demo n.co.uk/>
Mob: +44 (0)7811-639972
Tel: +44 (0)1235-811095
Going Forth Safely ..... EBA. www.electric-boat-association.org.uk..
*************** *************** *************** *************** ********
Jan 12 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
2515
by: Andy Fish | last post by:
Hi, in my c# code I have something like this: try { ... } catch (Exception ex) { ... throw ex; }
3
5458
by: Mike Schilling | last post by:
Instances of SystemOutOfMemoryException do not contain a stack trace. Easy test to verify this: class OOM { public static void Main() { try { Object arr = new Object; } catch (Exception ex) { dumpEx(ex);
0
3677
by: Mike Schilling | last post by:
I have some code that calls methods reflectively (the method called and its parameters are determined by text received in a SOAP message, and I construct a map from strings to MethodInfos). The code that does the call looks roughly like: try { // do reflective call response = method.Invoke(obj, params); }
1
4786
by: Jason Coyne | last post by:
I am trying to use the StackTrace class to get my current stack trace for some logging. Everything is working fine, except when I am using threading (specifically WaitCallBack and ThreadPool.QueueUserWorkItem) When I try to walk the stack from a location that has been called via QueueUserWorkItem, the stack stops at the point where the thread was launched. Is there a way to walk back further into the parent thread's stack (at the time...
3
24524
by: Jeremy | last post by:
While working with ASP.NET I've sometimes encountered errors in my applications, but I've always known exactly why I'm getting the error and have been able to fix it. So I've never needed to understand the Stack Trace, but I want to understand the stack trace so can somebody please explain it to me or point me to something that will Thanks Jeremy
2
4390
by: Lasse Vågsæther Karlsen | last post by:
If I got the following code: try { // something that might throw an exception } catch (Exception ex) { // Log contents of ex here throw;
3
3720
by: barker7 | last post by:
I am calling an unmanaged C++ method from C#. When an exception occurs in the C++ code, it gets caught in our C# code. CSharpMethod() { try { NativeCPPMethod(); } catch (Exception e)
5
1951
by: Mr. SweatyFinger | last post by:
WHY CAN'T THE CLOWN -HOLES WHO WROTE ASP.NET PROVIDE AN ERROR LINE NUMBER??? HONEST TO SH@THOLE PETE Server Error in '/New Folder (7)' Application. -------------------------------------------------------------------------------- The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE operator. Description: An unhandled exception occurred during the execution of the current web request....
4
11388
by: call_me_anything | last post by:
Here is a code to have a debug printf : #ifdef DEBUG #define DEBUG_printf(...) {printf(":",__FUNCTION__);printf(__VA_ARGS__);printf("\n");} #else #define DEBUG #endif int main () {
3
7228
by: Dave Anson | last post by:
I have a custom exception and I want to write the information to the event log, including the Stack Trace. I can create the message and write to the event log no problem, but the Stack Trace is empty. How do I append the Stack Trace in the custom exception? I can get the inner exception stack trace from the system exceptions, but how do I get my own stack trace information. Thanks in advance
0
9423
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10047
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9995
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9863
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8872
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7410
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6674
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5447
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3962
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.