Commit 62286c0c authored by mark's avatar mark

build and serial flash utility now works for the pi

parent dbbe2bea
......@@ -111,12 +111,12 @@ CDEFS += --std=c11
# for hard floating point support we must add: -mthumb -march=armv7e-m -mfloat-abi=hard -mfpu=fpv4-sp-d16 to both the compiler and linker stages. see https://launchpadlibrarian.net/186123405/readme.txt
# for soft floating point add:-mthumb -mcpu=cortex-m4 -mfloat-abi=softfp -mfpu=fpv4-sp-d16
# for no floating point support add: -mthumb -mcpu=cortex-m4
FP_SUPPORT = -mcpu=cortex-m3 -mthumb
FP_SUPPORT = -mthumb -mcpu=cortex-m3 -march=armv7
CFLAGS = -flto -ffunction-sections -fdata-sections -O0 -Wall
# Note: the default is to compile little-endian but we will also explicitly define it
CFLAGS += -mlittle-endian
CFLAGS += -mlittle-endian -mthumb -mcpu=cortex-m3 -march=armv7-m
# Wl: passes the following commands to the linker
# for the smaller newlib version subistute -lm with -specs=nano.specs
......@@ -194,8 +194,8 @@ ifneq ($(USER), pi)
flash: $(OUTPUT_DIR)/$(TARGET).elf
openocd -f $(OPENOCD_INTERFACE_CFG) -f $(OPENOCD_BOARD_CFG) -c "program $(OUTPUT_DIR)/$(TARGET).elf verify reset"
else
flash: $(OUTPUT_DIR)/$(TARGET).elf
stm32flash -w $(OUTPUT_DIR)/$(TARGET).elf -v -g 0x0 /dev/ttyAMA0
flash: $(OUTPUT_DIR)/$(TARGET).elf hex
stm32flash -w $(OUTPUT_DIR)/$(TARGET).hex -v -g 0x0 /dev/ttyAMA0
endif
hex: $(OUTPUT_DIR)/$(TARGET).hex
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment