summaryrefslogtreecommitdiff
path: root/openocd.cfg
diff options
context:
space:
mode:
Diffstat (limited to 'openocd.cfg')
-rw-r--r--openocd.cfg25
1 files changed, 25 insertions, 0 deletions
diff --git a/openocd.cfg b/openocd.cfg
new file mode 100644
index 0000000..15a42d4
--- /dev/null
+++ b/openocd.cfg
@@ -0,0 +1,25 @@
+source [find interface/stlink-v2.cfg]
+source [find target/stm32f1x.cfg]
+
+telnet_port disabled
+tcl_port disabled
+
+if { [info exists HLA_SERIAL] } {
+ # If set with -c use that by default
+} elseif { [info exists env(HLA_SERIAL)] } {
+ eval "set HLA_SERIAL $env(HLA_SERIAL)"
+}
+
+if { [info exists HLA_SERIAL] } {
+ hla_serial $HLA_SERIAL
+}
+
+if { [info exists GDB_PORT] } {
+ # If set with -c use that by default
+} elseif { [info exists env(GDB_PORT)] } {
+ set GDB_PORT $env(GDB_PORT)
+} else {
+ set GDB_PORT 3333
+}
+
+gdb_port $GDB_PORT