Skip to content

Instantly share code, notes, and snippets.

@xypron
Created February 17, 2024 12:29
Show Gist options
  • Save xypron/09a82594047b9f736c09f5839ff90272 to your computer and use it in GitHub Desktop.
Save xypron/09a82594047b9f736c09f5839ff90272 to your computer and use it in GitHub Desktop.
OpenOCD configuration of SiFive HiFive Unmatched
adapter speed 10000
adapter driver ftdi
ftdi device_desc "Dual RS232-HS"
ftdi vid_pid 0x0403 0x6010
ftdi layout_init 0x0008 0x001b
ftdi layout_signal nSRST -oe 0x0020 -data 0x0020
set _CHIPNAME riscv
transport select jtag
jtag newtap $_CHIPNAME cpu -irlen 5
# Target: S7 (coreid 0) and U74 (coreid 1-4)
target create $_CHIPNAME.cpu0 riscv -chain-position $_CHIPNAME.cpu -coreid 0 -rtos hwthread
target create $_CHIPNAME.cpu1 riscv -chain-position $_CHIPNAME.cpu -coreid 1
target create $_CHIPNAME.cpu2 riscv -chain-position $_CHIPNAME.cpu -coreid 2
target create $_CHIPNAME.cpu3 riscv -chain-position $_CHIPNAME.cpu -coreid 3
target create $_CHIPNAME.cpu4 riscv -chain-position $_CHIPNAME.cpu -coreid 4
target smp $_CHIPNAME.cpu0 $_CHIPNAME.cpu1 $_CHIPNAME.cpu2 $_CHIPNAME.cpu3 $_CHIPNAME.cpu4
init
halt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment