This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Max stack usage, can uVision register it?

Hi All,

Anyone knows if uVision can register the maximum stack usage in debug mode?.. Is very useful to run the code in the target and then check the maximum usage of the stack in any moment in order to be safe about the size. Perhaps anyone knows a better way to calculate it.

Thanks

Parents
  • This is easy to accomplish.
    Fill the stack area with a known pattern (0xDEADBEEF or whatever) at your program initialization in the code or using debug macros. Run the program for a while. Inspect stack area to see how much of the pattern was overwritten (can be automated as well.)

Reply
  • This is easy to accomplish.
    Fill the stack area with a known pattern (0xDEADBEEF or whatever) at your program initialization in the code or using debug macros. Run the program for a while. Inspect stack area to see how much of the pattern was overwritten (can be automated as well.)

Children