Skip to content

Commit aefd48b

Browse files
erdnaxedpgeorge
authored andcommitted
samd/Makefile: Specify UF2 family in firmware.uf2.
Set the UF2 firmware images family to Microchip SAMD21 or SAMD51. This helps tools such as file to identify built firmware. Signed-off-by: Alexandre Iooss <[email protected]>
1 parent e23fdb1 commit aefd48b

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

ports/samd/Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ $(BUILD)/firmware.bin: $(BUILD)/firmware.elf
183183
$(Q)$(OBJCOPY) -O binary -j .isr_vector -j .text -j .data $^ $(BUILD)/firmware.bin
184184

185185
$(BUILD)/firmware.uf2: $(BUILD)/firmware.bin
186-
$(Q)$(PYTHON) $(UF2CONV) -b $(TEXT0) -c -o $@ $<
186+
$(Q)$(PYTHON) $(UF2CONV) $(UF2CONV_FLAGS) -b $(TEXT0) -c -o $@ $<
187187

188188
# pin_af.c: $(BUILD)/$(GEN_PIN_AF) | $(HEADER_BUILD)
189189

ports/samd/mcu/samd21/mpconfigmcu.mk

+2
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@ endif
1313
MICROPY_VFS_LFS1 ?= 1
1414

1515
SRC_S += shared/runtime/gchelper_thumb1.s
16+
17+
UF2CONV_FLAGS += -f 0x68ed2b88

ports/samd/mcu/samd51/mpconfigmcu.mk

+2
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,5 @@ SRC_S += shared/runtime/gchelper_thumb2.s
1414

1515
SRC_C += \
1616
fatfs_port.c \
17+
18+
UF2CONV_FLAGS += -f 0x55114460

0 commit comments

Comments
 (0)