Skip to content

Commit

Permalink
tools: px_uploader.py: change RuntimeErorr to printf warning for fw_m…
Browse files Browse the repository at this point in the history
…axsize greater than fw_maxsize (#24321)
  • Loading branch information
dakejahl authored Feb 13, 2025
1 parent 195961a commit b77797b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Tools/px_uploader.py
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,7 @@ def upload(self, fw_list, force=False, boot_delay=None, boot_check=False, force_
# https://github.com/PX4/Firmware/blob/master/src/drivers/boards/common/stm32/board_mcu_version.c#L125-L144

if self.fw_maxsize > fw.property('image_maxsize') and not force:
raise RuntimeError(f"Board can accept larger flash images ({self.fw_maxsize} bytes) than board config ({fw.property('image_maxsize')} bytes). Please use the correct board configuration to avoid lacking critical functionality.")
print(f"WARNING: Board can accept larger flash images ({self.fw_maxsize} bytes) than board config ({fw.property('image_maxsize')} bytes)")
else:
# If we're still on bootloader v4 on a Pixhawk, we don't know if we
# have the silicon errata and therefore need to flash px4_fmu-v2
Expand Down

0 comments on commit b77797b

Please sign in to comment.