Eclipse GDB (DSF) Remote Debugging

The goal is to setup the simple remote debugging facility of Eclipse for cross target debugging. The target need to run the gdbserver. With this solution, it is only possible to debug the application on user level.

Debug configuration

Create a new debug configuration for a remote target. Open Debug Configurations.. and add a new launch configuration under C/C++ Remote Application.

bildschirmfoto_vom_2021-05-21_18-42-57

Tab main

Project: Select the project to debug, e.g. SOEM and in C/C++ Application: Local build generated elf-file to upload and debug on target, e.g. ${workspace_loc:SOEM/build/Debug/test/linux/simple_test/simple_test}.

bildschirmfoto_vom_2021-05-21_18-49-47

Connection: Create a new connection to the target (There is no reference to RSE). Keep in mind, that the user given here is used for executing the gdbserver and the application under debug. Sometimes there is a need for executing gdbserver as root.

bildschirmfoto_vom_2021-05-21_17-48-25

Tab Arguments

A few arguments can be passed to the application:

bildschirmfoto_vom_2021-06-04_13-54-15

Tab Debugger

The host debugger must be set to the multi-arch debugger to work properly the the remote gdbserver.

bildschirmfoto_vom_2021-06-04_13-55-53

The rest of the tabs should be left unchanged.

Prepare target

For opening a debugging session to the target, there is a GDB-server needed on the target. Login to BBB and install gdb-server.

debian@beaglebone:~$ sudo apt-get install gdbserver

Previous Post Next Post