diff --git a/Makefile b/Makefile --- a/Makefile +++ b/Makefile @@ -69,6 +69,8 @@ Src/stm32f0xx_hal_msp.c \ Src/stm32f0xx_it.c \ Src/system_stm32f0xx.c \ Src/system.c \ +Src/i2c.c \ +Src/sgp30.c \ hydrobot-sharedlibs/src/can_buffer.c \ hydrobot-sharedlibs/src/can.c \ hydrobot-sharedlibs/src/flash.c \ @@ -164,6 +166,9 @@ LDFLAGS = $(MCU) -specs=nano.specs -T$(L # default action: build all all: $(BUILD_DIR)/$(TARGET).elf $(BUILD_DIR)/$(TARGET).hex $(BUILD_DIR)/$(TARGET).bin +# flash via serial wire debug +flash: all + st-flash --reset write $(BUILD_DIR)/$(TARGET).bin 0x8000000 ####################################### # build the application