Updated: 

https://github.com/openocd-org/openocd/blob/v0.12.0-rc1/src/jtag/drivers/cmsis_dap_usb_bulk.c#L340-L342
Not sure, but should it also return ERROR_FAIL here,  or contine for next `for` 
loop, to make an fallback like all other place does?


---

** [tickets:#368] openocd don't proper fallback and not work on 
cmsis-dap-v1(hid) with  `CMSIS DAP` in name of its usb serial**

**Status:** new
**Milestone:** 0.11.0
**Created:** Sat Oct 15, 2022 04:08 AM UTC by yyjdelete
**Last Updated:** Sat Oct 15, 2022 04:08 AM UTC
**Owner:** nobody


Some cmsis-dap-v1 devices has an usb serial and  `CMSIS DAP` in it's name.
Seems openocd choose to workaroud bug for `KitProg3` by search  `CMSIS DAP` in 
all usb devices, and not only WinUSB, but it also broken supported for all 
cmsis-dap-v1(hid) devices with an usb serial and  `CMSIS DAP` in the name of 
serial(it will use cmsis-dap-v2 and failed)
https://github.com/openocd-org/openocd/blob/v0.12.0-rc1/src/jtag/drivers/cmsis_dap_usb_bulk.c#L249-L273
One workaround is make a copy of `cmsis-dap.cfg`, add `cmsis_dap_backend hid` 
to the new file and use the new one. But maybe it should works out of box by 
add an separately `cmsis-dap-v1.cfg`, do auto fallback to v1,  use whitelist 
for special error devices, or use blacklist for usb serial with `CMSIS DAP` in 
name.

https://github.com/openocd-org/openocd/blob/v0.12.0-rc1/src/jtag/drivers/cmsis_dap_usb_bulk.c#L340-L342
Not sure, but should it also return FAIL here to make an fallback like all 
other place does?

Many error report can be found on the web.
https://www.google.com/search?q=Warn+%3A+Using+CMSIS-DAPv2+interface+1+with+wrong+class+10+subclass+0+or+protocol+0
https://github.com/search?q=cmsis_dap_backend+hid&type=issues


---

Sent from sourceforge.net because openocd-devel@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/openocd/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/openocd/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.


Reply via email to