Skip to content
Snippets Groups Projects
Commit f6741b71 authored by Thomas Eichinger's avatar Thomas Eichinger
Browse files

SQUASHME: adding ports for openocd

parent 7dbb1fd6
No related branches found
No related tags found
No related merge requests found
...@@ -5,6 +5,11 @@ if [ ! -f "$2" ]; then ...@@ -5,6 +5,11 @@ if [ ! -f "$2" ]; then
exit 1 exit 1
fi fi
# if GDB_PORT does not exist or holds empty string
if [ -z ${GDB_PORT} ]; then
GDB_PORT=0
fi
echo "##" echo "##"
echo "## Debugging $2" echo "## Debugging $2"
echo "##" echo "##"
...@@ -12,6 +17,7 @@ echo "##" ...@@ -12,6 +17,7 @@ echo "##"
openocd -f "board/stm32f3discovery.cfg" \ openocd -f "board/stm32f3discovery.cfg" \
-c "tcl_port 6333" \ -c "tcl_port 6333" \
-c "telnet_port 4444" \ -c "telnet_port 4444" \
-c "gdb_port ${GDB_PORT}"
-c "init" \ -c "init" \
-c "targets" \ -c "targets" \
-c "reset halt" \ -c "reset halt" \
......
...@@ -6,6 +6,9 @@ echo "##" ...@@ -6,6 +6,9 @@ echo "##"
openocd -f "board/stm32f3discovery.cfg" \ openocd -f "board/stm32f3discovery.cfg" \
-c "init" \ -c "init" \
-c "tcl_port 0" \
-c "telnet_port 0" \
-c "gdb_port 0" \
-c "targets" \ -c "targets" \
-c "reset halt" \ -c "reset halt" \
-c "program $1 0x08000000 verify" \ -c "program $1 0x08000000 verify" \
......
...@@ -6,5 +6,8 @@ echo "##" ...@@ -6,5 +6,8 @@ echo "##"
openocd -f "board/stm32f3discovery.cfg" \ openocd -f "board/stm32f3discovery.cfg" \
-c "init" \ -c "init" \
-c "tcl_port 0" \
-c "telnet_port 0" \
-c "gdb_port 0" \
-c "reset run"\ -c "reset run"\
-c "shutdown" -c "shutdown"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment