Open UweBonnes opened 3 years ago
So CMSIS-DAP is a HID device , and so is your mouse. I access them via the hidapi library. https://github.com/libusb/hidapi If you haven't done so I recommend that you get and install the latest version of this library. I haven't seen any interference issues between this code and other HID devices so the hidapi library being used may be a source of variance.
I installed 0.9.0 for OpenSuse, but the problem persists. From the git page, hidapi-0.9.0 seems the latest. Otherwise I use hidapi also for the black magic probe debugger https://github.com/blacksphere/blackmagic/ . But I search via libusb for CMSIS-DAP devices and only later handle a cmsid-dap device found with hidapi.
BMP is also the cause for my interest in rvdbg. There is https://github.com/blacksphere/blackmagic/pull/292 and another branch starting riscv support. As BMP now also works with cmsis-dap and jlink, I can have one setup and test with rvdbg and bmp and so hope to get riscv support going. #292 is not for the present riscv debug version.
0.10.1 is the latest. That ok, I've actually been running 0.8.rc1. After a 6 year break they've started doing work on the library again.
If you have a segger jlink you might want to try that. 1) It's not HID so I don't think it'll have a problem with mice. 2) It's faster than CMSIS-DAP - that may be a bug in my cmsis-dap interface code, but at the moment the jlink is quite a bit faster.
It is OK with 0.10.1 . Regarding speed: CMSIS-DAP can read and write chunks of memory on ARM with one USB command, so reading chunks on riscv needs to be assembled from lower level commands and probably needs a lot of USB round trips. libjaylink probably is more intelligent here.
OK with 0.10.1
Good to know.
read and write chunks of memory on ARM with one USB command
For my usage of CMSIS-DAP and Jlink they both use basic JTAG operations - neither supports any macro operations to read/write RISC-V memory. But yes- fast USB is about minimising round trip transactions, and it may be that I can do something else to bundle together multiple state machine operations into a single USB transaction thereby achieve some speedup.
Getting RISCV support into BMP would be another option. BMP can be used as is, with the GDB server running on the dongle and gdb attaching to the dongle usb-serial gdb device or with the gdb server running on the host and the PC exchanging low-and high level (SWD/Jtag) commands with the dongle via USB/serial. Running the server on the PC helps to develop algorithms.
I'm not a big fan on the "gdb server on dongle" approach the BMP guys are using. I tend to like the idea of dongles just being jtag/swd so you can use put all the smarts in the host software. E.g. platform specific register field decodes.
In any case I tried hidapi 0.10.1 and that works fine for me. This is the CMSIS-DAP device I use:
Hello,
I can see the GD32FV chips now. Debugger is a LPCLinkV2 with newest firmware.