探索全新的 mydSPACE 服务: 许可证管理、全新的 dSPACE 帮助以及用于用户文档的 dSPACE 聊天机器人。请访问我们的专用支持页面,获取更多信息和支持。 链接了解更多并获取支持

FAQ 566: Debugging Virtual Artifacts with Eclipse IDE

Question

How do I attach the debugger to a simulation running in VEOS using Eclipse IDE?

Solution

Debugging the source code during SIL simulation is useful. It allows you to set breakpoints, inspect variables, and step through the code. The V-ECU workflow allows you to integrate ECU code into a simulated artifact, allowing errors to be identified early in development. During the integration process, it is often advantageous to use a debugger to investigate faults and errors in more detail. VEOS allows external debuggers to be attached to VPUs that are built with the Debug configuration.

To debug source code in a SIL simulation using Eclipse IDE:

  1. Load the offline simulation application (OSA) to VEOS.
  1. Get the unique Process ID from the Properties window of VEOS or via the Task Manager.
  1. Start Eclipse IDE.
  2. In the Eclipse window, create a new C/C++ project.
     
  1. In the Classic C Project dialog, enter the name of the debug project, select the compiler, and click Finish.
  1. Right-click on the debug project you created and select New-> Folder.
  1. In the New Folder dialog, select the current debug project and provide the path of the VEOS Build folder (containing source files, binaries and *.dll generated). Click “Finish”.
  1. In the Eclipse window, select Open Perspective, then select Debug from the dialog that opens.
  1. In the Eclipse window, click Debug and select Debug Configurations.
  1. In the Debug Configurations window, right-click on C/C++ Attach to Application and select “New Configuration”.
  1. In the new debug configuration that was created, give a name to the configuration in the “Main” tab. In the C/C++ Application field, enter the path of the *.dll file that was generated during the VEOS build. In the Build Configuration, select “Debug” and select the “Disable auto build” option.
  1. In the “Debugger Options” pane, define the path of the compiler.
  1. In the “Add Source” dialog, add a new compilation directory. Then, provide the path to the folder containing the source files and binaries in the VEOS build folder.
  1. Set up an example breakpoint. Once the VEOS simulation is loaded, check the Process ID.
  1. In the Eclipse window, set the breakpoint at the required lines in the code and click “Debug Configuration”. Select the debug project and click “Debug”.
  1. A new window opens. Search for the Process ID as seen in VEOS and click OK.
  1. In the Debug window, click the “Resume” icon.
  1. Navigate to VEOS and start the simulation. Once the debugger is connected, “Call Trace” will be visible and the simulation is paused until the debugger resumes execution[JP..

Related Topics

  • FAQ 557
    FAQ 557

    How do I attach the debugger to a running VEOS simulation?

Tags

Date 2026-10-16
产品 VEOS
资料信息 常见问答
dSPACE 版本发布 2026-A
Keywords SIL Support Central

通过 dSPACE时事通讯服务了解最新信息。

通过 dSPACE 时事通讯服务,我们将随时向您通报当前的使用案例、新解决方案和产品以及培训和活动。在此注册,免费订阅。

Enable form call

At this point, an input form from Click Dimensions is integrated. This enables us to process your newsletter subscription. The form is currently hidden due to your privacy settings for our website.

External input form

By activating the input form, you consent to personal data being transmitted to Click Dimensions within the EU, in the USA, Canada or Australia. More on this in our privacy policy.