@@ -15,6 +15,54 @@
# along with this program; if not, write to the Free Software
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
# MMDVM source files
MMDVM_PATH = .
# STM32 library paths
F4_LIB_PATH = ./STM32F4XX_Lib
F7_LIB_PATH = ./STM32F7XX_Lib
# MCU external clock frequency (Hz)
CLK_MMDVM_PI = 12000000
CLK_NUCLEO = 8000000
# Directory Structure
BINDIR = bin
OBJDIR_F4 = obj_f4
OBJDIR_F7 = obj_f7
# Output files
BINELF_F4 = mmdvm_f4.elf
BINHEX_F4 = mmdvm_f4.hex
BINBIN_F4 = mmdvm_f4.bin
BINELF_F7 = mmdvm_f7.elf
BINHEX_F7 = mmdvm_f7.hex
BINBIN_F7 = mmdvm_f7.bin
# Header directories
INC_F4 = . $( F4_LIB_PATH) /CMSIS/Include/ $( F4_LIB_PATH) /Device/ $( F4_LIB_PATH) /STM32F4xx_StdPeriph_Driver/include/
INCLUDES_F4 = $( INC_F4:%= -I%)
INC_F7 = . $( F7_LIB_PATH) /CMSIS/Include/ $( F7_LIB_PATH) /Device/ $( F7_LIB_PATH) /STM32F7xx_StdPeriph_Driver/inc/
INCLUDES_F7 = $( INC_F7:%= -I%)
# CMSIS libraries
INCLUDES_LIBS_F4 = $( F4_LIB_PATH) /CMSIS/Lib/GCC/libarm_cortexM4lf_math.a
INCLUDES_LIBS_F7 = $( F7_LIB_PATH) /CMSIS/Lib/GCC/libarm_cortexM7lfsp_math.a
# STM32F4 Standard Peripheral Libraries source path
STD_LIB_F4 = $( F4_LIB_PATH) /STM32F4xx_StdPeriph_Driver/source
# STM32F7 Standard Peripheral Libraries source path
STD_LIB_F7 = $( F7_LIB_PATH) /STM32F7xx_StdPeriph_Driver/src
# STM32F4 system source path
SYS_DIR_F4 = $( F4_LIB_PATH) /Device
STARTUP_DIR_F4 = $( F4_LIB_PATH) /Device/startup
# STM32F7 system source path
SYS_DIR_F7 = $( F7_LIB_PATH) /Device
STARTUP_DIR_F7 = $( F7_LIB_PATH) /Device/startup
# GNU ARM Embedded Toolchain
# GNU ARM Embedded Toolchain
CC = arm-none-eabi-gcc
CC = arm-none-eabi-gcc
CXX = arm-none-eabi-g++
CXX = arm-none-eabi-g++
@@ -27,65 +75,44 @@ NM=arm-none-eabi-nm
SIZE = arm-none-eabi-size
SIZE = arm-none-eabi-size
A2L = arm-none-eabi-addr2line
A2L = arm-none-eabi-addr2line
# Directory Structure
BINDIR = bin
# Find source files
# Find source files
# "SystemRoot" is only defined in Windows
# "SystemRoot" is only defined in Windows
i f d e f S Y S T E M R O O T
i f d e f S Y S T E M R O O T
ASOURCES = $( shell dir /S /B *.s)
CSOURCES = $( shell dir /S /B *.c)
CXXSOURCES = $( shell dir /S /B *.cpp)
CLEANCMD = del /S *.o *.hex *.bin *.elf GitVersion.h
CLEANCMD = del /S *.o *.hex *.bin *.elf GitVersion.h
MDBIN = md $@
MDDIRS = md $@
e l s e i f d e f S y s t e m R o o t
e l s e i f d e f S y s t e m R o o t
ASOURCES = $( shell dir /S /B *.s)
CSOURCES = $( shell dir /S /B *.c)
CXXSOURCES = $( shell dir /S /B *.cpp)
CLEANCMD = del /S *.o *.hex *.bin *.elf GitVersion.h
CLEANCMD = del /S *.o *.hex *.bin *.elf GitVersion.h
MDBIN = md $@
MDDIRS = md $@
e l s e
e l s e
ASOURCES = $( shell find . -name '*.s' )
CLEANCMD = rm -f $( OBJ_F4 ) $( OBJ_F7 ) $( BINDIR ) /*.hex $( BINDIR ) /*.bin $( BINDIR ) /*.elf GitVersion.h
CSOURCES = $( shell find . -name '*.c' )
MDDIRS = mkdir $@
CXXSOURCES = $( shell find . -name '*.cpp' )
CLEANCMD = rm -f $( OBJECTS) $( BINDIR) /$( BINELF) $( BINDIR) /$( BINHEX) $( BINDIR) /$( BINBIN) GitVersion.h
MDBIN = mkdir $@
e n d i f
e n d i f
# Default reference oscillator frequencies
# Default reference oscillator frequencies
i f n d e f $( OSC )
i f n d e f $( OSC )
i f e q ( $( MAKECMDGOALS ) , p i )
i f e q ( $( MAKECMDGOALS ) , p i )
OSC = 12000000
OSC = $( CLK_MMDVM_PI )
else
else
OSC = 8000000
OSC = $( CLK_NUCLEO )
endif
endif
e n d i f
e n d i f
# Find header directorie s
# Build object list s
INC_F4 = . STM32F4XX_Lib/CMSIS/Include/ STM32F4XX_Lib/Device/ STM32F4XX_Lib/STM32F4xx_StdPeriph_Driver/include/
CXXSRC = $( wildcard $( MMDVM_PATH ) /*.cpp )
INCLUDES_F4 = $( INC_F4:% = -I% )
CSRC_STD_F4 = $( wildcard $( STD_LIB_F4 ) /*.c )
INC_F7 = . STM32F7XX_Lib/CMSIS/Include/ STM32F7XX_Lib/Device/ STM32F7XX_Lib/STM32F7xx_StdPeriph_Driver/inc/
SYS_F4 = $( wildcard $( SYS_DIR_F4 ) /*.c )
INCLUDES_F7 = $( INC_F7:% = -I% )
STARTUP_F4 = $( wildcard $( STARTUP_DIR_F4 ) /*.c )
CSRC_STD_F7 = $( wildcard $( STD_LIB_F7) /*.c)
SYS_F7 = $( wildcard $( SYS_DIR_F7) /*.c)
STARTUP_F7 = $( wildcard $( STARTUP_DIR_F7) /*.c)
OBJ_F4 = $( CXXSRC:$( MMDVM_PATH) /%.cpp= $( OBJDIR_F4) /%.o) $( CSRC_STD_F4:$( STD_LIB_F4) /%.c= $( OBJDIR_F4) /%.o) $( SYS_F4:$( SYS_DIR_F4) /%.c= $( OBJDIR_F4) /%.o) $( STARTUP_F4:$( STARTUP_DIR_F4) /%.c= $( OBJDIR_F4) /%.o)
OBJ_F7 = $( CXXSRC:$( MMDVM_PATH) /%.cpp= $( OBJDIR_F7) /%.o) $( CSRC_STD_F7:$( STD_LIB_F7) /%.c= $( OBJDIR_F7) /%.o) $( SYS_F7:$( SYS_DIR_F7) /%.c= $( OBJDIR_F7) /%.o) $( STARTUP_F7:$( STARTUP_DIR_F7) /%.c= $( OBJDIR_F7) /%.o)
# Find librarie s
# MCU flag s
INCLUDES_LIBS_F4 = STM32F4XX_Lib/CMSIS/Lib/GCC/libarm_cortexM4lf_math.a
INCLUDES_LIBS_F7 = STM32F7XX_Lib/CMSIS/Lib/GCC/libarm_cortexM7lfsp_math.a
# Create object list
OBJECTS = $( ASOURCES:%.s= %.o)
OBJECTS += $( CSOURCES:%.c= %.o)
OBJECTS += $( CXXSOURCES:%.cpp= %.o)
# Define output files ELF & IHEX
BINELF = outp.elf
BINHEX = outp.hex
BINBIN = outp.bin
# MCU FLAGS
MCFLAGS_F4 = -mcpu= cortex-m4 -mthumb -mlittle-endian -mfpu= fpv4-sp-d16 -mfloat-abi= hard -mthumb-interwork
MCFLAGS_F4 = -mcpu= cortex-m4 -mthumb -mlittle-endian -mfpu= fpv4-sp-d16 -mfloat-abi= hard -mthumb-interwork
MCFLAGS_F7 = -mcpu= cortex-m7 -mthumb -mlittle-endian -mfpu= fpv5-sp-d16 -mfloat-abi= hard -mthumb-interwork
MCFLAGS_F7 = -mcpu= cortex-m7 -mthumb -mlittle-endian -mfpu= fpv5-sp-d16 -mfloat-abi= hard -mthumb-interwork
# COMPILE FLAGS
# Compile flags
# STM32F4 Discovery board:
# STM32F4 Discovery board:
DEFS_DIS = -DUSE_STDPERIPH_DRIVER -DSTM32F4XX -DSTM32F40_41xxx -DSTM32F4_DISCOVERY -DHSE_VALUE= $( OSC) -DMADEBYMAKEFILE
DEFS_DIS = -DUSE_STDPERIPH_DRIVER -DSTM32F4XX -DSTM32F40_41xxx -DSTM32F4_DISCOVERY -DHSE_VALUE= $( OSC) -DMADEBYMAKEFILE
# MMDVM-Pi board:
# MMDVM-Pi board:
@@ -95,122 +122,168 @@ DEFS_NUCLEO=-DUSE_STDPERIPH_DRIVER -DSTM32F4XX -DSTM32F446xx -DSTM32F4_NUCLEO -D
# STM32F7 Nucleo-144-F767ZI board:
# STM32F7 Nucleo-144-F767ZI board:
DEFS_NUCLEO_F767 = -DUSE_HAL_DRIVER -DSTM32F767xx -DSTM32F7XX -DSTM32F7_NUCLEO -DHSE_VALUE= $( OSC) -DMADEBYMAKEFILE
DEFS_NUCLEO_F767 = -DUSE_HAL_DRIVER -DSTM32F767xx -DSTM32F7XX -DSTM32F7_NUCLEO -DHSE_VALUE= $( OSC) -DMADEBYMAKEFILE
# Build compiler flags
CFLAGS_F4 = -c $( MCFLAGS_F4) $( INCLUDES_F4)
CFLAGS_F4 = -c $( MCFLAGS_F4) $( INCLUDES_F4)
CXXFLAGS_F4 = -c $( MCFLAGS_F4) $( INCLUDES_F4)
CXXFLAGS_F4 = -c $( MCFLAGS_F4) $( INCLUDES_F4)
CFLAGS_F7 = -c $( MCFLAGS_F7) $( INCLUDES_F7)
CFLAGS_F7 = -c $( MCFLAGS_F7) $( INCLUDES_F7)
CXXFLAGS_F7 = -c $( MCFLAGS_F7) $( INCLUDES_F7)
CXXFLAGS_F7 = -c $( MCFLAGS_F7) $( INCLUDES_F7)
# LINKER FLAGS
# Linker flags
LDFLAGS_F4 = -T stm32f4xx_link.ld $( MCFLAGS_F4) --specs= nosys.specs $( INCLUDES_LIBS_F4)
LDFLAGS_F4 = -T stm32f4xx_link.ld $( MCFLAGS_F4) --specs= nosys.specs $( INCLUDES_LIBS_F4)
LDFLAGS_F7 = -T stm32f7xx_link.ld $( MCFLAGS_F7) --specs= nosys.specs $( INCLUDES_LIBS_F7)
LDFLAGS_F7 = -T stm32f7xx_link.ld $( MCFLAGS_F7) --specs= nosys.specs $( INCLUDES_LIBS_F7)
# COMMON FLAGS
# Common flags
CFLAGS = -Os -ffunction-sections -fdata-sections -fno-builtin -Wno-implicit -DCUSTOM_NEW -DNO_EXCEPTIONS
CFLAGS = -Os -ffunction-sections -fdata-sections -fno-builtin -Wno-implicit -DCUSTOM_NEW -DNO_EXCEPTIONS
CXXFLAGS = -Os -fno-exceptions -ffunction-sections -fdata-sections -fno-builtin -fno-rtti -DCUSTOM_NEW -DNO_EXCEPTIONS
CXXFLAGS = -Os -fno-exceptions -ffunction-sections -fdata-sections -fno-builtin -fno-rtti -DCUSTOM_NEW -DNO_EXCEPTIONS
LDFLAGS = -Os --specs= nano.specs
LDFLAGS = -Os --specs= nano.specs
# Build Rules
# Build Rules
.PHONY : all release dis pi nucleo clean
.PHONY : all release dis pi nucleo f 767 clean
# Default target: STM32F4 Nucleo F446RE board
# Default target: STM32F4 Nucleo F446RE board
all : nucleo
all : nucleo
pi : GitVersion .h
pi : GitVersion .h
pi : CFLAGS +=$( CFLAGS_F 4) $( DEFS_PI )
pi : CFLAGS +=$( CFLAGS_F 4) $( DEFS_PI )
pi : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_PI )
pi : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_PI )
pi : LDFLAGS +=$( LDFLAGS_F 4)
pi : LDFLAGS +=$( LDFLAGS_F 4)
pi : release
pi : release_f 4
nucleo : GitVersion .h
nucleo : GitVersion .h
nucleo : CFLAGS +=$( CFLAGS_F 4) $( DEFS_NUCLEO )
nucleo : CFLAGS +=$( CFLAGS_F 4) $( DEFS_NUCLEO )
nucleo : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_NUCLEO )
nucleo : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_NUCLEO )
nucleo : LDFLAGS +=$( LDFLAGS_F 4)
nucleo : LDFLAGS +=$( LDFLAGS_F 4)
nucleo : release
nucleo : release_f 4
dis : GitVersion .h
dis : GitVersion .h
dis : CFLAGS +=$( CFLAGS_F 4) $( DEFS_DIS )
dis : CFLAGS +=$( CFLAGS_F 4) $( DEFS_DIS )
dis : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_DIS )
dis : CXXFLAGS +=$( CXXFLAGS_F 4) $( DEFS_DIS )
dis : LDFLAGS +=$( LDFLAGS_F 4)
dis : LDFLAGS +=$( LDFLAGS_F 4)
dis : release
dis : release_f 4
f767 : GitVersion .h
f767 : GitVersion .h
f767 : CFLAGS +=$( CFLAGS_F 7) $( DEFS_NUCLEO_F 767)
f767 : CFLAGS +=$( CFLAGS_F 7) $( DEFS_NUCLEO_F 767)
f767 : CXXFLAGS +=$( CXXFLAGS_F 7) $( DEFS_NUCLEO_F 767)
f767 : CXXFLAGS +=$( CXXFLAGS_F 7) $( DEFS_NUCLEO_F 767)
f767 : LDFLAGS +=$( LDFLAGS_F 7)
f767 : LDFLAGS +=$( LDFLAGS_F 7)
f767 : release
f767 : release_f 7
release : $( BINDIR )
release_f4 : $( BINDIR )
release : $( BINDIR ) / $( BINHEX )
release_f4 : $( OBJDIR_F 4)
release : $( BINDIR ) /$( BINBIN )
release_f4 : $( BINDIR ) /$( BINHEX_F 4)
release_f4 : $( BINDIR ) /$( BINBIN_F 4)
release_f7 : $( BINDIR )
release_f7 : $( OBJDIR_F 7)
release_f7 : $( BINDIR ) /$( BINHEX_F 7)
release_f7 : $( BINDIR ) /$( BINBIN_F 7)
$(BINDIR) :
$(BINDIR) :
$( MDBIN )
$( MDDIRS )
$(BINDIR)/$(BINHEX) : $( BINDIR ) / $( BINELF )
$(OBJDIR_F4) :
$( MDDIRS)
$(OBJDIR_F7) :
$( MDDIRS)
$(BINDIR)/$(BINHEX_F4) : $( BINDIR ) /$( BINELF_F 4)
$( CP) -O ihex $< $@
$( CP) -O ihex $< $@
@echo "Objcopy from ELF to IHEX complete!\n"
@echo "Objcopy from ELF to IHEX complete!\n"
$(BINDIR)/$(BINBIN) : $( BINDIR ) /$( BINELF )
$(BINDIR)/$(BINBIN_F4 ) : $( BINDIR ) /$( BINELF_F 4)
$( CP) -O binary $< $@
$( CP) -O binary $< $@
@echo "Objcopy from ELF to BINARY complete!\n"
@echo "Objcopy from ELF to BINARY complete!\n"
$(BINDIR)/$(BINELF) : $( OBJECTS )
$(BINDIR)/$(BINELF_F4 ) : $( OBJ_F 4)
$( CXX) $( OBJECTS ) $( LDFLAGS) -o $@
$( CXX) $( OBJ_F4 ) $( LDFLAGS) -o $@
@echo "Linking complete!\n"
@echo "Linking complete!\n"
$( SIZE) $( BINDIR) /$( BINELF)
$( SIZE) $( BINDIR) /$( BINELF_F4 )
%.o : %.cpp
$(BINDIR)/$(BINHEX_F7) : $( BINDIR ) /$( BINELF_F 7)
$( CP) -O ihex $< $@
@echo "Objcopy from ELF to IHEX complete!\n"
$(BINDIR)/$(BINBIN_F7) : $( BINDIR ) /$( BINELF_F 7)
$( CP) -O binary $< $@
@echo "Objcopy from ELF to BINARY complete!\n"
$(BINDIR)/$(BINELF_F7) : $( OBJ_F 7)
$( CXX) $( OBJ_F7) $( LDFLAGS) -o $@
@echo "Linking complete!\n"
$( SIZE) $( BINDIR) /$( BINELF_F7)
$(OBJDIR_F4)/%.o : $( MMDVM_PATH ) /%.cpp
$( CXX) $( CXXFLAGS) $< -o $@
$( CXX) $( CXXFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
@echo "Compiled " $<"!\n"
%.o : %.c
$(OBJDIR_F7)/%.o : $( MMDVM_PATH ) / %.cpp
$( CXX) $( CXXFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
$(OBJDIR_F4)/%.o : $( STD_LIB_F 4) /%.c
$( CC) $( CFLAGS) $< -o $@
$( CC) $( CFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
@echo "Compiled " $<"!\n"
%.o : %.s
$(OBJDIR_F7)/%.o : $( STD_LIB_F 7) / %.c
$( CC) $( CFLAGS) $< -o $@
$( CC) $( CFLAGS) $< -o $@
@echo "Assamb led " $<"!\n"
@echo "Compi led " $<"!\n"
$(OBJDIR_F4)/%.o : $( SYS_DIR_F 4) /%.c
$( CC) $( CFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
$(OBJDIR_F4)/%.o : $( STARTUP_DIR_F 4) /%.c
$( CC) $( CFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
$(OBJDIR_F7)/%.o : $( SYS_DIR_F 7) /%.c
$( CC) $( CFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
$(OBJDIR_F7)/%.o : $( STARTUP_DIR_F 7) /%.c
$( CC) $( CFLAGS) $< -o $@
@echo "Compiled " $<"!\n"
clean :
clean :
$( CLEANCMD)
$( CLEANCMD)
deploy :
deploy :
i f n e q ( $( wildcard /usr /bin /openocd ) , )
i f n e q ( $( wildcard /usr /bin /openocd ) , )
/ u s r / b i n / o p e n o c d - f / u s r / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ u s r / b i n / o p e n o c d - f / u s r / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF_F4 ) verify reset exit"
e n d i f
e n d i f
i f n e q ( $( wildcard /usr /local /bin /openocd ) , )
i f n e q ( $( wildcard /usr /local /bin /openocd ) , )
/ u s r / l o c a l / b i n / o p e n o c d - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ u s r / l o c a l / b i n / o p e n o c d - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF_F4 ) verify reset exit"
e n d i f
e n d i f
i f n e q ( $( wildcard /opt /openocd /bin /openocd ) , )
i f n e q ( $( wildcard /opt /openocd /bin /openocd ) , )
/ o p t / o p e n o c d / b i n / o p e n o c d - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ o p t / o p e n o c d / b i n / o p e n o c d - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 4 x . c f g - c "program bin/$(BINELF_F4 ) verify reset exit"
e n d i f
e n d i f
deploy-f7 :
deploy-f7 :
i f n e q ( $( wildcard /usr /bin /openocd ) , )
i f n e q ( $( wildcard /usr /bin /openocd ) , )
/ u s r / b i n / o p e n o c d - f / u s r / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ u s r / b i n / o p e n o c d - f / u s r / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF_F7 ) verify reset exit"
e n d i f
e n d i f
i f n e q ( $( wildcard /usr /local /bin /openocd ) , )
i f n e q ( $( wildcard /usr /local /bin /openocd ) , )
/ u s r / l o c a l / b i n / o p e n o c d - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ u s r / l o c a l / b i n / o p e n o c d - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / u s r / l o c a l / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF_F7 ) verify reset exit"
e n d i f
e n d i f
i f n e q ( $( wildcard /opt /openocd /bin /openocd ) , )
i f n e q ( $( wildcard /opt /openocd /bin /openocd ) , )
/ o p t / o p e n o c d / b i n / o p e n o c d - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF) verify reset exit"
/ o p t / o p e n o c d / b i n / o p e n o c d - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / i n t e r f a c e / s t l i n k - v 2 - 1 . c f g - f / o p t / o p e n o c d / s h a r e / o p e n o c d / s c r i p t s / t a r g e t / s t m 3 2 f 7 x . c f g - c "program bin/$(BINELF_F7 ) verify reset exit"
e n d i f
e n d i f
deploy-pi :
deploy-pi :
i f n e q ( $( wildcard /usr /local /bin /stm 32flash ) , )
i f n e q ( $( wildcard /usr /local /bin /stm 32flash ) , )
-/usr/local/bin/stm32flash -i 20,-21,21 : -20, 21 /dev /ttyAMA 0
-/usr/local/bin/stm32flash -i 20,-21,21 : -20, 21 /dev /ttyAMA 0
-/usr/local/bin/stm32ld /dev/ttyAMA0 57600 bin/outp.bin
-/usr/local/bin/stm32ld /dev/ttyAMA0 57600 bin/$( BINBIN_F4 )
/usr/local/bin/stm32flash -v -w bin/outp.bin -g 0x0 -R -c /dev/ttyAMA0
/usr/local/bin/stm32flash -v -w bin/$( BINBIN_F4 ) -g 0x0 -R -c /dev/ttyAMA0
e n d i f
e n d i f
i f n e q ( $( wildcard /usr /bin /stm 32flash ) , )
i f n e q ( $( wildcard /usr /bin /stm 32flash ) , )
-/usr/bin/stm32flash -i 20,-21,21 : -20, 21 /dev /ttyAMA 0
-/usr/bin/stm32flash -i 20,-21,21 : -20, 21 /dev /ttyAMA 0
-/usr/bin/stm32ld /dev/ttyAMA0 57600 bin/outp.bin
-/usr/bin/stm32ld /dev/ttyAMA0 57600 bin/$( BINBIN_F4 )
/usr/bin/stm32flash -v -w bin/outp.bin -g 0x0 -R -c /dev/ttyAMA0
/usr/bin/stm32flash -v -w bin/$( BINBIN_F4 ) -g 0x0 -R -c /dev/ttyAMA0
e n d i f
e n d i f
# Export the current git version if the index file exists, else 000...
# Export the current git version if the index file exists, else 000...