DAPLink icon indicating copy to clipboard operation
DAPLink copied to clipboard

Disallow both CMSIS-DAP v1 and v2 to be opened simultaneously

Open flit opened this issue 6 years ago • 4 comments

In interface firmware configurations where both CMSIS-DAP v1 and v2 USB interfaces are available, there is a possibility that the user could open both CMSIS-DAP interfaces concurrently. This will, of course, cause unpredictable behaviour.

A real world example is with multicore debug using Keil µVision. If starting a debug session in one µVision instance with the CMSIS-DAP v1 interface, and the CMSIS-DAP v2 interface is selected in the setup dialog of another µVision instance, then the debug connection in the first is lost. The same happens the other way around (debug session with CMSIS-DAPv2 and setup dialog with CMSIS-DAPv1).

The solution is to disallow simultaneous opening of both CMSIS-DAP interfaces. The actual mechanism used to disable a CMSIS-DAP interface needs to be investigated.

flit avatar Sep 13 '19 15:09 flit

I have always sort of wished that DAPLink could expose another usb->com port specifically for exposing a CLI to configure the probe. Yet another usb endpoint though.

Not a fan of serial escape sequences or I'd say use that as an alternative.

0Grit avatar Sep 13 '19 20:09 0Grit

A CLI is an interesting idea. But I think the drag-and-drop configuration files are probably easier for most people. And they become a sort of command line interface when activated with commands like touch /Volumes/FRDM-K64FD/auto_rst.cfg.

Do multiple CDC virtual com ports require additional USB interfaces? I don't know CDC well enough to know the answer to that.

flit avatar Sep 13 '19 20:09 flit

@aglass0fmilk ^

Do multiple CDC virtual com ports require additional USB interfaces? I don't know CDC well enough to know the answer to that.

0Grit avatar Sep 13 '19 20:09 0Grit

Recently, I try to test a v1+v2 CMSIS-DAP, I got same conflicting issues. Suggest to use a slide-switch as v1 or v2 selection(upgrade FW) .

RadioOperator avatar Sep 23 '19 04:09 RadioOperator