Ashling* RiscFree* Integrated Development Environment (IDE) for Altera® FPGAs User Guide

ID 730783
Date 4/11/2025
Public
Document Table of Contents

3.4.3. Setting Debug Configurations and Downloading Arm HPS Project Using Visual Studio Code

Follow these steps to debug the project:
  1. Go to ASHLING PROJECT VIEW > agilex7-a53-picojpeg > Debug Configurations. Click the + icon beside Debug Configurations to list down the supported launch configurations. Click ARM Hardware Debugging and specify a name for the launch.
    Figure 150. Debug Configurations
    Figure 151.  Create ARM Hardware Debugging
  2. A debug configuration window appears, .elf file is auto selected from the project in the Main tab. You can select a different .elf by using Browse feature.
    Figure 152. Debug Configurations for ARM Processor—Main Tab
  3. Click Debugger tab, and click the drop-down icon to select the appropriate debug probe for the debug session.
  4. Under the Debugger tab, set these settings:
    • Debug probe: Agilex SI/SoC Dev Kit (Name of the FPGA board/development kit)
    • Transport type: JTAG
    • JTAG frequency: 16 MHz
    • Core selection: Can select any core between 0 to 3
  5. Click Auto-detect Scan Chain to automatically detect JTAG scan chain information of the target device. Select the options from Tap selection and Core selection.
    Figure 153. Debug Configurations for ARM Processor — Debugger Tab (Part 1)
    Figure 154. Debug Configurations for ARM Processor — Debugger Tab (Part 2)
    Note: The default settings for the current example design in the Visual Studio Code are configured based on the Agilex™ 7 device.
    Note: If you are using a different Arm architecture, select the Arm GNU debugger (GDB) (select GDB Client Setup > Executable name) manually.
    • 64-bit ELFs: ${eclipse_home}/../toolchain/Arm/aarch64- none-elf/bin/aarch64-none-elf-gdb.exe
    • 32-bit ELFs: ${eclipse_home}/../toolchain/Arm/arm-noneeabi/ bin/arm-none-eabi-gdb.exe
  6. Leave all other settings, including those in the Startup tab, as sensible defaults have been set.
  7. Click Debug in the top right corner of the launch configuration dialog.
  8. Visual Studio Code downloads the program to the target SoC and display its progress through the console prints.
Figure 155. Debug Configurations for ARM Processor — Startup Tab and Debug Button
Figure 156.  Visual Studio Code after Program is Downloaded and System is Ready for Debug