Mistake on this page?
Report an issue in GitHub or email us

Setting up to debug Mbed OS programs

You need to update the new DAPLink interface firmware, which includes the new target support, on your interface MCU.

To include the new target support:

  1. Clone the latest DAPLink firmware with the new target support completed above.
  2. Use the DAPLink instructions to build the DAPLink firmware release package.
  3. Locate the generated .bin or .hex firmware under DAPLink\uvision_release\<your_board_name_if>.
  4. To update the interface firmware:
    1. Press the Reset button.
    2. Plug the USB cable to the host.
    3. Drag-n-drop the interface firmware.

Create GDB pyOCD debug configuration

  1. Install pyOCD. You need the version with the new target support. If you contributed to PyOCD and an updated version hasn't been released yet, you can invoke the local copy:

    pip install --editable <path_to_pyOCD_with_new_target_support>

    Make a note of the installation path of pyocd-gdbserver; you'll need it when you set up the debug configuration inside the IDE.

  2. The following example is for Eclipse IDE; find similar settings for Keil and IAR.

    1. Under Debugger, point the Executable path and Actual executable path to the pyocd-gdbserver you installed earlier.

      For example: /Library/Frameworks/Python.framework/Versions/2.7/bin/pyocd-gdbserver on macOS.

    2. In GDB Client Setup, change the executable to arm-none-eabi-gdb, which was part of the GNU Arm Embedded Toolchain you installed earlier.

      For example, on Windows, it looks like:

      C:\Program Files (x86)\GNU Tools ARM Embedded\7 2017-q4-major\bin\arm-none-eabi-gdb.exe

      On macOS, it may be:

  3. You can use the default values for all other settings.

Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.