#40 Can debug C/C++ App, Can't debug GDB SEGGER Jlink....

Version 1.x
closed
nobody
None
5
2014-08-22
2014-02-26
Ronald
No

First, let me say that the Gnu Arm Plugin is a fantastic piece of work! Pure Genius!!!

I'm sure I'm doing something silly, but I cannot debug under "GDB SEGGER J-Link Debugging".

Configuration:

Target Device: AT91SAM7X512

Eclipse Kepler SR1
ilg.gnuarmeclipse.repository-2.1.2-201402180751
CodeSourcery arm-2013.11-24-arm-none-eabi
Windows 8.1

I am able to get this to work, if I create a debug configuration under "C/C++ Application".

Jpg's 1, 2, and 3 show my configuration and the program running under the debugger. I can set and execute breakpoints, and if I remove all breakpoints, the program runs normally.

If I create a debug config under "GDB SEGGER J-Link Debugging", (Jpg 4, 5, 6) things don't work....

If I use the default GDB Client Setup, I get the result in Jpg 7.

If I copy my startup commands from my successfully running "C/C++ Application config, I
get the result in Jpg 8. The program executes on the target board, but the pause button is
unavailable

If I change the config from "Standard Create Process Launcher" to
"GDB (DSF) Create Process Launcher", I get a dialog saying
"Problem Occurred Launching Sourcery_C2 has encountered a problem. Error
while launching command: gdb --version."

The test program is a simple Led flashing program (main.c).

8 Attachments

Related

Support requests: #40

Discussion

  • jpegs 1 & 2 are missing, but I assume you are using the GDB Hardware Debugging plug-in, with the gdb server started as an external application.

    I'm not used to the AT91SAM7X512, but the configuration seems ok.

    first attempts to understand the problem were not successful, I'll try to analyse it again tomorrow.

     
    • Ronald
      Ronald
      2014-02-27

      Hi,

      Attached are jpg's 1 & 2....

      Thanks for the great work,

      Ron

       
      Last edit: Liviu Ionescu (ilg) 2014-02-27
      • hmmm... you used C/C++ Apps... that might sometimes work, but they were not intended for this.

        I can't figure out what is wrong, seems like something messed in Eclipse.

        could you retry in a fresh workspace, after reading carefully the documentation pages?

         
        • Ronald
          Ronald
          2014-02-27

          Hi,

          I will try that.....

          I have seen a couple of documents on-line which detail a step-by-step procedure for setting up a debug config using C/C++ Applications, they pretty much duplicate my config.

          Another interesting thing... a couple of plugin revs ago, I was able to use Segger Jlink by checking "Attach to Running Target", an option which is no longer available.

          I can do a complete reinstall of Eclipse... do you recommend to install the CDT version, or the standard version and then install the CDT master?

          Please do not spend too much time on this, everything has been working well using C/C++ Apps, other than I have to remember to manually start the GDB server.....

          Thanks,

          Ron

           
          Last edit: Liviu Ionescu (ilg) 2014-02-27
          Attachments
          • I can do a complete reinstall of Eclipse... do you recommend to install the CDT version, or the standard version and then install the CDT master?

            I guess both are fine.

            but no need to do this, just disable the second reset and it should work.

            ... "Attach to Running Target"

            this is not yet fully implemented by Segger. but, as a side effect, this disabled the second reset, this explains why it worked

            everything has been working well using C/C++ Apps, other than I have to remember to manually start the GDB server.....

            yes, this is one of the reasons I wrote the plug-in, to be sure the server is correctly and freshly started


            one more thing, please use the tracker web interface, and do not reply by email, since this always quotes the long original message

             
  • Error while launching command: gdb --version."

    this sounds like a path problem, if you are using the gdb hardware plug-in, it does not automatically use the toolchain path from the build plug-in, you have to set it explicitly in the path.

     
  • in the Startup tab you need to disable Pre-run reset, this applies only to applications running from flash.

     
  • Ronald
    Ronald
    2014-02-27

    Problem Solved!

    I disabled "Pre-run reset" in the Startup tab per your recommendation, everything is now working! (I am running my test code in SRAM, not flash.....)

    Thank you so much for your patience and help, and for creating such a wonderful product!

     
    • you're welcome!

      can we close this ticket now?

       
      • Ronald
        Ronald
        2014-02-27

        Hi,

        Yes, please close, and thank you again!

        -Ron

        To: 40@support-requests.gnuarmeclipse.p.re.sf.net
        From: ilg-ul@users.sf.net
        Subject: [gnuarmeclipse:support-requests] Re: #40 Can debug C/C++ App, Can't debug GDB SEGGER Jlink....
        Date: Thu, 27 Feb 2014 17:20:07 +0000

        you're welcome!

        can we close this ticket now?

        [support-requests:#40] Can debug C/C++ App, Can't debug GDB SEGGER Jlink....

        Status: open

        Created: Wed Feb 26, 2014 11:04 PM UTC by Ronald

        Last Updated: Thu Feb 27, 2014 03:57 PM UTC

        Owner: nobody

        First, let me say that the Gnu Arm Plugin is a fantastic piece of work! Pure Genius!!!

        I'm sure I'm doing something silly, but I cannot debug under "GDB SEGGER J-Link Debugging".

        Configuration:

        Target Device: AT91SAM7X512

        Eclipse Kepler SR1

        ilg.gnuarmeclipse.repository-2.1.2-201402180751

        CodeSourcery arm-2013.11-24-arm-none-eabi

        Windows 8.1

        I am able to get this to work, if I create a debug configuration under "C/C++ Application".

        Jpg's 1, 2, and 3 show my configuration and the program running under the debugger. I can set and execute breakpoints, and if I remove all breakpoints, the program runs normally.

        If I create a debug config under "GDB SEGGER J-Link Debugging", (Jpg 4, 5, 6) things don't work....

        If I use the default GDB Client Setup, I get the result in Jpg 7.

        If I copy my startup commands from my successfully running "C/C++ Application config, I

        get the result in Jpg 8. The program executes on the target board, but the pause button is

        unavailable

        If I change the config from "Standard Create Process Launcher" to

        "GDB (DSF) Create Process Launcher", I get a dialog saying

        "Problem Occurred Launching Sourcery_C2 has encountered a problem. Error

        while launching command: gdb --version."

        The test program is a simple Led flashing program (main.c).

        Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnuarmeclipse/support-requests/40/

        To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

         

        Related

        Support requests: #40

        Attachments
    • status: open --> closed