summarylogtreecommitdiffstats
path: root/wch-riscv.cfg
diff options
context:
space:
mode:
authoryjun2023-08-13 17:46:46 +0800
committeryjun2023-08-13 17:46:46 +0800
commitd050fb35b77cb17ab1c0af0f5f594ca3773c3a17 (patch)
tree930edc50e340ef858f507c44b3e7ea9807441c51 /wch-riscv.cfg
parent45cc67028cb6b72011e90e76e8bd70de71117b90 (diff)
downloadaur-riscv-openocd-wch.tar.gz
fix dirctories conflicts and add wch link config
Diffstat (limited to 'wch-riscv.cfg')
-rw-r--r--wch-riscv.cfg15
1 files changed, 15 insertions, 0 deletions
diff --git a/wch-riscv.cfg b/wch-riscv.cfg
new file mode 100644
index 000000000000..651ec252d700
--- /dev/null
+++ b/wch-riscv.cfg
@@ -0,0 +1,15 @@
+#interface wlink
+adapter driver wlink
+wlink_set
+set _CHIPNAME riscv
+jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x00001
+
+set _TARGETNAME $_CHIPNAME.cpu
+
+target create $_TARGETNAME.0 riscv -chain-position $_TARGETNAME
+$_TARGETNAME.0 configure -work-area-phys 0x80000000 -work-area-size 10000 -work-area-backup 1
+set _FLASHNAME $_CHIPNAME.flash
+
+flash bank $_FLASHNAME wch_riscv 0x00000000 0 0 0 $_TARGETNAME.0
+
+echo "Ready for Remote Connections"