昨天wchlink調(diào)試ch32v307正常,今天發(fā)現(xiàn)啟動(dòng)調(diào)試錯(cuò)誤,通過usb下載ch32v307工作是正常的,懷疑wchlink的問題, 請(qǐng)問wchlink固件在哪能下載到,希望刷一下wchlink試試。 手動(dòng)調(diào)用openocd,錯(cuò)誤如下: C:\MounRiver\MounRiver_Studio\toolchain\OpenOCD\bin>openocd?-f?wch-riscv.cfg Open?On-Chip?Debugger?0.11.0+dev-02215-gcc0ecfb6d-dirty?(2022-03-30-19:10) Licensed?under?GNU?GPL?v2 For?bug?reports,?read ????????http://openocd.org/doc/doxygen/bugs.html Info?:?only?one?transport?option;?autoselect?'jtag' Ready?for?Remote?Connections Info?:?Listening?on?port?6666?for?tcl?connections Info?:?Listening?on?port?4444?for?telnet?connections Info?:?WCH-Link?version?2.3 Info?:?wlink_init?ok Info?:?This?adapter?doesn't?support?configurable?speed Info?:?JTAG?tap:?riscv.cpu?tap/device?found:?0x00000001?(mfg:?0x000?(),?part:?0x0000,?ver:?0x0) Warn?:?Bypassing?JTAG?setup?events?due?to?errors Error:?OpenOCD?only?supports?Debug?Module?version?2?(0.13)?and?3?(1.0),?not?0?(dmstatus=0x0).?This?error?might?be?caused?by?a?JTAG?signal?issue.?Try?reducing?the?JTAG?clock?speed. Warn?:?target?riscv.cpu.0?examination?failed Error:?Debug?Module?did?not?become?active.?dmcontrol=0x0 Error:?Debug?Module?did?not?become?active.?dmcontrol=0x0 Info?:?starting?gdb?server?for?riscv.cpu.0?on?3333 Info?:?Listening?on?port?3333?for?gdb?connections Error:?Debug?Module?did?not?become?active.?dmcontrol=0x0 Error:?Debug?Module?did?not?become?active.?dmcontrol=0x0 Error:?OpenOCD?only?supports?Debug?Module?version?2?(0.13)?and?3?(1.0),?not?0?(dmstatus=0x0).?This?error?might?be?caused?by?a?JTAG?signal?issue.?Try?reducing?the?JTAG?clock?speed. Error:?Debug?Module?did?not?become?active.?dmcontrol=0x0 s
問題解決了,是杜邦線太差了,換根線就好了
我也遇到這類問題,WCHLINK的RISCV燒錄調(diào)試協(xié)議抗干擾能力特別差,在稍微有一丁點(diǎn)干擾的地方就會(huì)各種報(bào)錯(cuò),幾乎無法正常調(diào)試.數(shù)次發(fā)帖詢問,官方要么硬說沒問題,要么答非所問.? 調(diào)到絕望了,下次做產(chǎn)品還是選coetex-m核的mcu.
這是我遇得最多的情況,調(diào)試過程中,突然openocd輸出一堆報(bào)錯(cuò)信息,然后就斷開了.
您好,根據(jù)截圖信息,報(bào)錯(cuò)可能是由Link傳輸數(shù)據(jù)錯(cuò)誤或者是芯片狀態(tài)不對(duì)導(dǎo)致的,可以檢查一下WCH-Link模式是否正確,正常對(duì)RISC-V MCU下載調(diào)試時(shí),狀態(tài)應(yīng)該是空閑時(shí)紅燈常亮藍(lán)燈常滅。此外,使用Link下載調(diào)試時(shí),注意一下BOOT接法,BOOT0接VCC,BOOT1接GND。最后,注意使用Link下載時(shí),連接Link和MCU的杜邦線不要過長,盡量短一些,調(diào)式時(shí)程序中最好不要有FLASH相關(guān)操作,或者開啟看門狗、低功耗模式,都會(huì)影響仿真。
我這邊也遇到類似的問題, 板子是 官方的 CH32V307 最小系統(tǒng)。剛開始是正常的,gdb連接上去過個(gè) 5min~ 15min 就會(huì)出錯(cuò),報(bào)錯(cuò)為見圖。
Open?On-Chip?Debugger?0.11.0+dev-02415-gfad123a16-dirty?(2023-02-22-15:09) Licensed?under?GNU?GPL?v2 For?bug?reports,?read ????????http://openocd.org/doc/doxygen/bugs.html Info?:?only?one?transport?option;?autoselect?'sdi' Warn?:?Transport?"sdi"?was?already?selected Ready?for?Remote?Connections Info?:?WCH-LinkE??mode:RV?version?2.8? Info?:?wlink_init?ok Info?:?clock?speed?6000?kHz Info?:?[wch_riscv.cpu.0]?datacount=2?progbufsize=8 Info?:?[wch_riscv.cpu.0]?Examined?RISC-V?core;?found?1?harts Info?:?[wch_riscv.cpu.0]??XLEN=32,?misa=0x40901125 [wch_riscv.cpu.0]?Target?successfully?examined. Info?:?starting?gdb?server?for?wch_riscv.cpu.0?on?3333 Info?:?Listening?on?port?3333?for?gdb?connections Info?:?Listening?on?port?6666?for?tcl?connections Info?:?Listening?on?port?4444?for?telnet?connections