Add ability to debug the microcontroller
This commit is contained in:
8
Makefile
8
Makefile
@@ -65,6 +65,14 @@ assemble: compile $(OBJ_FILES)
|
||||
flash: $(BUILD_DIR)/$(TARGET).bin
|
||||
st-flash --reset write $< 0x8000000
|
||||
|
||||
.PHONY: gdb-server
|
||||
gdb-server:
|
||||
sudo openocd -f stlink.cfg -f stm32f4x.cfg
|
||||
|
||||
.PHONY: gdb-client
|
||||
gdb-client:
|
||||
gdb --symbols $(BUILD_DIR)/$(TARGET).elf --init-eval-command="target extended-remote localhost:3333"
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
rm -rf $(BUILD_DIR)
|
||||
|
||||
Reference in New Issue
Block a user