bernardofca

Forum Replies Created

Viewing 5 posts - 16 through 20 (of 20 total)
  • Author
    Posts
  • in reply to: Setting up heap and stack size #7819
    bernardofca
    Participant

    For the record in case someone looks at this thread:

    I agree that the default setting of the heap and stack works well (this is really an issue if one is running an OS). My problem was caused by a function that had local variables that were consuming a huge amount of stack space. The problem was not easy to find because the data corruption was happening randomly on function calls (but not necessarily on the offending one). I was able to find the problem by stepping through the program and monitoring the stack pointer. When I stepped in the offending function, I saw a huge jump in the stack.

    in reply to: Setting up heap and stack size #7801
    bernardofca
    Participant

    Thanks for the response. Yes, I have seen the information regarding _sbrk()…

    I am trying to debug a problem whereby global variables are overwritten when jumping to a function. With the debugger I see that the corruption has occurred during the jump. It looks like a stack corruption but I cannot find the problem (yet!).

    in reply to: semihosting print too slow #7070
    bernardofca
    Participant

    Thanks for the answer. At least I know that this is an expected behavior. I have a debug UART on the PCB but I am waiting for the mating connector!

    in reply to: Debug string without printf #6130
    bernardofca
    Participant

    I was actually too quick to answer: the Newlib-nano reduces the size of the code but the output does not go to the debugger window. I will need to fix that…

    in reply to: Debug string without printf #6115
    bernardofca
    Participant

    The Newlib-nano fixed the problem – thanks

Viewing 5 posts - 16 through 20 (of 20 total)