Menu

#466 The issue with versions of CH347 5.44 and 4.41

0.12.0
new
nobody
ch347 (1)
4 days ago
4 days ago
No

The problem is that OpenOCD works with chip version 4.41 (31102xd41 chip mark, Firmware=0x41), but an error occurs with version 5.44 (31452hf17, Firmware=0x45).

For linux:

ch347.cfg
adapter driver ch347
ch347 vid_pid 0x1a86 0x55dd
adapter speed 1000

output:
$ ./openocd -f ./ch347.cfg -f ./mytarget.cfg
Open On-Chip Debugger 0.12.0+dev-01373-gb9e401616 (2026-02-16-14:28)
Licensed under GNU GPL v2
For bug reports, read
adapter speed: 1000 kHz
Info : set servers polling period to 200ms
Warn : DEPRECATED: auto-selecting transport "jtag". Use 'transport select jtag' to suppress this message.
Info : CH347 USB To UART+JTAG from vendor wch.cn with serial number 0123456789 found. (Chip version=5.44, Firmware=0x45)
Info : Requested speed of 1000 kHz is not possible. Using the next higher speed of 1875 kHz!
Info : Requested speed of 1000 kHz is not possible. Using the next higher speed of 1875 kHz!
Info : clock speed 1875 kHz
Info : JTAG tap: riscv.cpu tap/device found: 0xdeb11001 (mfg: 0x000 (<invalid>), part: 0xeb11, ver: 0xd)
Info : JTAG tap: riscv.sys tap/device found: 0xfffffffe (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Info : [riscv.cpu] datacount=2 progbufsize=6
Info : [riscv.cpu] Examined RISC-V core
Info : [riscv.cpu] XLEN=32, misa=0x40001104
Info : [riscv.cpu] Examination succeed
Info : [riscv.cpu] starting gdb server on 3333
Info : Listening on port 3333 for gdb connections
init done
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Error: libusb_bulk_read error: LIBUSB_ERROR_OVERFLOW
Error: CH347 read fail
Error: [riscv.cpu] Unable to execute JTAG queue
Error: [riscv.cpu] Polling failed, trying to reexamine
Error: Unsupported DTM version 1. (dtmcontrol=0x71)
Error: [riscv.cpu] Examination failed
Error: [riscv.cpu] Examination failed, GDB will be halted. Polling again in 100ms
openocd: src/target/riscv/batch.c:25: get_dmi_scan_length: Assertion `abits > 0' failed.</invalid></invalid>

  • for Windows:
    openocd master windows msys2 mingw64
    WinUSB driver interface 2
    log1*:
    Open On-Chip Debugger 0.12.0+dev-02419-g129e9d300 (2026-02-16-15:56)
    Licensed under GNU GPL v2
    For bug reports, read
    adapter speed: 938 kHz
    Info : set servers polling period to 200ms
    Info : CH347 USB To UART+JTAG from vendor (unknown) with serial number 0123456789 found. (Chip version=5.44, Firmware=0x45)
    Info : clock speed 938 kHz
    Error: libusb_bulk_read error: LIBUSB_ERROR_PIPE
    Error: CH347 read fail
    Error: Trying to use configured scan chain anyway...
    Error: libusb_bulk_read error: LIBUSB_ERROR_TIMEOUT
    Error: CH347 read fail
    Warn : Bypassing JTAG setup events due to errors
    Error: libusb_bulk_read error: LIBUSB_ERROR_TIMEOUT
    Error: CH347 read fail
    Error: 'dtmcs' scan failed on TAP riscv.cpu, error code = -6
    Error: [riscv.cpu] Could not read dtmcontrol. Check JTAG connectivity/board power.
    Error: [riscv.cpu] Examination failed
    Warn : target riscv.cpu examination failed
    Info : [riscv.cpu] starting gdb server on 3333
    Info : Listening on port 3333 for gdb connections
    Error: Target not examined yet
    C:\Users\user\Desktop\ch347-dev-files\mytarget.cfg:81: Error:
    Traceback (most recent call last):
    File "C:\Users\user\Desktop\ch347-dev-files\mytarget.cfg", line 81, in script
    {riscv.cpu arm semihosting} enable
    Error: [riscv.cpu] Unsupported DTM version: -1
    Error: [riscv.cpu] Could not identify target type.

log2:
Open On-Chip Debugger 0.12.0+dev-02419-g129e9d300 (2026-02-16-15:56)
Licensed under GNU GPL v2
For bug reports, read
adapter speed: 938 kHz
Info : set servers polling period to 200ms
Info : CH347 USB To UART+JTAG from vendor wch.cn with serial number 0123456789 found. (Chip version=5.44, Firmware=0x45)
Info : clock speed 938 kHz
Info : JTAG tap: riscv.cpu tap/device found: 0xdeb11001 (mfg: 0x000 (<invalid>), part: 0xeb11, ver: 0xd)
Info : JTAG tap: riscv.sys tap/device found: 0xfffffffe (mfg: 0x7ff (<invalid>), part: 0xffff, ver: 0xf)
Error: libusb_bulk_read error: LIBUSB_ERROR_PIPE
Error: CH347 read fail
Error: [riscv.cpu] Unable to execute JTAG queue
Error: [riscv.cpu] Examination failed
Warn : target riscv.cpu examination failed
Info : [riscv.cpu] starting gdb server on 3333
Info : Listening on port 3333 for gdb connections
Error: Target not examined yet
C:\Users\user\Desktop\ch347-dev-files\mytarget.cfg:81: Error:
Traceback (most recent call last):
File "C:\Users\user\Desktop\ch347-dev-files\mytarget.cfg", line 81, in script
{riscv.cpu arm semihosting} enable
Error: [riscv.cpu] Unsupported DTM version: -1
Error: [riscv.cpu] Could not identify target type.</invalid></invalid>

Discussion


Log in to post a comment.

MongoDB Logo MongoDB