From ea0c0ce7e1cee6d65e70ccd0723ea59e08662e19 Mon Sep 17 00:00:00 2001 From: Fredrik Thulin Date: Thu, 26 May 2016 13:27:04 +0200 Subject: Figure out if the user (me) has a NUCLEO board. --- bin/debug | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bin/debug') diff --git a/bin/debug b/bin/debug index 9309e66..f87a3b5 100755 --- a/bin/debug +++ b/bin/debug @@ -5,7 +5,9 @@ PROJ="${1?'project'}" OPENOCD=openocd OPENOCD_BOARD_DIR=/usr/share/openocd/scripts/board OPENOCD_PROC_FILE=stm32f4discovery.cfg -#OPENOCD_PROC_FILE=st_nucleo_f4.cfg +if [ "x`lsusb -d 0483:374b`" != "x" ]; then + OPENOCD_PROC_FILE=st_nucleo_f4.cfg +fi $OPENOCD -f $OPENOCD_BOARD_DIR/$OPENOCD_PROC_FILE & GDB=arm-none-eabi-gdb -- cgit v1.2.3