Linux Application Debugging using Arm DS
Overview Creating a Simple Hello World Linux Application using C Creating a New C Project Configuring the Settings for New Project Creating the Source Code and Building the Project Debug the Linux Application on a Fixed Virtual Platform Model Creating an Arm DS Debug Configuration and Connecting to a FVP Model Debug Views Stepping Through the Application Disconnecting from the Debug Connection
Creating an Arm DS Debug Configuration and Connecting to a FVP Model
- From the Arm DS main menu, select Run > Debug Configurations.
- In the Debug Configurations dialog:
a. Select "Generic Arm C/C++ Application" from the available options in the left side of Debug Configuration window.
b. Select "Press the New button to crate a configuration of the selected type" icon as shown in above picture.
c. This creates a new Arm DS debug configuration and displays the various tabs required to specify settings for loading your application on the target.
-
On the Debug Configurations dialog:
a. Give a name to the debug configuration. For example, HelloWorld_Linux_FVP.
b. In the Connection tab, select Arm FVP (Installed with Arm DS) > Cortex-A9x4 pre-configured to boot Arm Embedded Linux > Linux Application Debug > Start gdbserver and debug target resident application.
By default, a relative path to your workspace location is specified in the Host mount point field. This location is used by the /writeable directory specified in the Remote target mount point field.
c. In the Files tab, and under Target Configuration > Application on target field, enter /writeable/HelloWorld_GCC/Debug/HelloWorld_GCC. This specifies that the HelloWorld_GCC application is available under the/writeable/HelloWorld_GCC/Debug/ location on the target.
d. Under Files, select Load symbols from a file, and click Workspace.
e. In the Open dialog, select the HelloWorld_GCC application in the Debug folder.
f. Click OK. This sets the path to the file that contains the required symbols information.
g. Select the Debugger tab, and select Debug from the entry point.
h. Click Debug to load the application on the target, and load the debug information into the debugger.
i. In the Confirm Perspective Switch dialog that appears, click Yes.
Arm DS-connects to the FVP model loads Linux on the FVP model and displays the connection status in the Debug Control view.The application is loaded on the target and has stopped at the entry point, ready to run.