lpc176x: Add build rules for smoothieware bootloader support

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2018-05-17 11:00:24 -04:00
parent c381d03aad
commit 4344f7fc10
2 changed files with 10 additions and 1 deletions

View File

@ -25,6 +25,15 @@ config CLOCK_FREQ
default 25000000 if MACH_LPC1768 # 100000000 / 4
default 30000000 if MACH_LPC1769 # 120000000 / 4
config SMOOTHIEWARE_BOOTLOADER
bool "Target board uses Smoothieware bootloader"
default y
config FLASH_START
hex
default 0x4000 if SMOOTHIEWARE_BOOTLOADER
default 0x0000
config USBSERIAL
bool "Use USB for communication (instead of serial)"
default y

View File

@ -33,7 +33,7 @@ target-y := $(OUT)LPC1768.ld $(target-y)
$(OUT)LPC1768.ld: lib/lpc176x/device/TOOLCHAIN_GCC_ARM/LPC1768.ld $(OUT)board-link
@echo " Preprocessing $@"
$(Q)$(CPP) -P -MD -MT $@ $< -o $@
$(Q)$(CPP) -P -MD -MT $@ -DMBED_APP_START=$(CONFIG_FLASH_START) -DMBED_APP_SIZE="(512K - $(CONFIG_FLASH_START))" $< -o $@
# Build the additional bin output file
target-y += $(OUT)klipper.bin