[SOLVED] Cannot step through c code source, only disassembly

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] Cannot step through c code source, only disassembly

    I cannot step through source c code, only disassembly. When I set a breakpoint in main() for example, the code breaks at the breakpoint but then if I "step into" it always goes to the disassembly window. I've been using embedded studio for a number of months without this problem, but it has now become an issue. It happens with both the debug and release builds, but only with this project. Other projects step through c code just fine.
  • Hello,

    Thank you for your inquiry.
    Usually this issue appears if source files are moved around and their absolute path on your filesystem changes so the debugger can't reference the disassembly with the source code anymore.
    Could you try issuing a rebuild of your project instead of just a build? Does this improve the behaviour?
    If not recheck the paths of your source files and see if they match the paths on your filesystem. Where possible we recommend using relative paths.

    Best regards,
    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • I tried the rebuild again and it didn't fix it. The source files have not moved and the paths match. I'm working with two related projects simultaneously, and now the second project is exhibiting the same problem whereas it was working just a day ago. This makes it tough to debug.
  • Hello,

    We currently have no other user pending with such issue so it is most likely it is related to your particular project setup.
    Could you provide an example project for reproduction on an evaluation board?

    Best regards,
    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • I have the same issue with SEGGER Embedded Studio for ARM 5.10, it started happening after the update to SEGGER Embedded Studio for ARM 4.52c and the update to 5.10 did not fix the issue.

    SEGGER seems to be unable to resolve any other files other than main.c.

    I performed the steps above about rebuilding project (&solution) but it did not help.

    The source files have not moved and the paths match -> this is also true for my project.

    I am using relative paths throughout the project (as it is shared with other collaborators via git).

    Interestingly, when I open the Breakpoints window and right-click the breakpoint and select "Go To Source Code", this:
    - works fine when not in debugger mode
    - does not work in debugger mode (there's no reaction whatsoever)

    Any other hints that you could give to fix it?
  • Hi,
    As my colleague Nino already inquired:

    Could you provide an example project for reproduction on an evaluation board?

    Best regards,
    Fabian
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi,

    Ok good to hear that you are up and running again.
    We will consider this thread as closed now.

    Best regards,
    Nino
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.