Creating a Linux Application and Debugging in the Vitis Software
Platform
- Launch the Vitis software platform.
- Create a Linux application by following these steps:
- Select File –> Go to New
Application Project.
- Create a platform from the provided .xsa file.
- Choose a name for your application and select the target
processor.
- Specify domain details, setting the Operating System to
Linux.
- Select an application template (for example, Hello
World).
- Select File –> Go to New
Application Project.
- Choose the application you wish to debug.
- Select Run –> Debug
Configuration.
- Click Launch on Hardware (Single Application
Debug) to create a new configuration.
- In the Debug Configuration window, follow these steps:
- In the Main Tab, do the
following:
- From the Debug Type drop-down list, select Linux Application Debug.
- From the Connection drop-down list, choose Linux agent.
- In the Application Tab, provide the
necessary information:
- In the Remote File Path field, specify the path in Linux where you want to download the application.
- If your application expects any command-line arguments, specify them in
the Arguments tab.
- If your application relies on specific environment variables, define them
in the Environment tab.
- Set up the target connection by entering the Linux hostname or IP address
in the Hostname field.
Note: By default, the tcf-agent runs on port 1534 on the Linux machine. If you use a different port, update the Port field with the correct port number.
- In the Main Tab, do the
following:
- Click the Debug button. This opens a
separate console for processing standard I/O operations.
- Set breakpoints by double-clicking on the desired lines of code.
- To continue execution, click Resume.
- For stepping through the code, follow these options:
- Step Over
- Click this to execute the current line and move to the next line in the
same function.
- Step-In
- Click this to enter into a called function.
- Step-Rerun
- Click this to re-execute the current line.
- To continue running the application after stepping through the code, click
Resume again.