CMSIS-DAP stands for ‘Cortex Microcontroller Software Interface Standard – Debug Access Port’) has been published by ARM Inc. With this, there is an open source alternative to proprietary implementation (e.g. P&E OpenSDA or Segger OpenSDA).
Beside of the ARM MDK IDE, CMSIS-DAP is supported by Coocox and IAR. And IAR is what I’m using in this post.
CMSIS-DAP Firmware for OpenSDA
The CMIS-DAP firmware sources are availble from ARM CMSIS-DAP: (requires registration). Unfortunately, this is set up to be compiled with the ARM/Keil MDK IDE :-(.
The good news is: the Freescale Quick Start Package includes a pre-built version of the firmware:
Download that zip file, then unpack the files. Updating the OpenSDA firmware follows the usual process:
- Power the FRDM-KL25Z with reset button pressed: green LED flashes.
- Copy the CMSIS-DAP_OpenSDA.s19 to the BOOTLOADER device.
- Repower the board without the reset button pressed.
Then the device should show up as ‘OpenSDA CMSIS-DAP’:
:!: CMSIS-DAP now does *not* support a virtual COM (USB CDC) port. Such a port is supported by the original P&E OpenSDA and as well by the USBDM OpenSDA.
CMSIS-DAP in IAR Embedded Workbench
Once I have a project in IAR, it is really simple to change it to use CMSIS-DAP. I use the menu Project > Options… and select CMSIS DAP as Driver:
Then the CMSIS-DAP is enabled, and it automatically has SWD (Single Wire Debug) selected:
That’s it! Now I can debug my application with CMSIS-DAP:
With the CMSIS-DAP I have another open source OpenSDA debug interface beside of USBDM. USBDM is supported by CodeWarrior, and CMSIS-DAP is supported by IAR/Keil/Coocox, so this makes it an attractive alternative for the ‘open source lovers’. The low-level bootloader of the OpenSDA is not Open Source, but with CMSIS-DAP the chances are good to have a fully open source run control hardware plus software for ARM cores. And that CMSIS-DAP would the de-facto standard to debug any ARM core. And mbed jumped on the CMSIS-DAP wagon already (see links below).
Happy DAPing :-)
- ARM CMSIS-DAP: (requires registration)
- Using Keil with Freedom Board and CMSIS-DAP
- Freescale Quick Start Package with CMSIS-DAP SDA Firmware
- mbed and CMSIS-DAP: https://mbed.org/handbook/CMSIS-DAP