Tools: handle unsupported ext flashsize

This commit is contained in:
Siddharth Purohit 2021-07-05 15:02:36 +05:30 committed by Andrew Tridgell
parent 7cf9db4cc9
commit 2dc51d9bae

View File

@ -673,7 +673,11 @@ class uploader(object):
self.board_type = self.__getInfo(uploader.INFO_BOARD_ID)
self.board_rev = self.__getInfo(uploader.INFO_BOARD_REV)
self.fw_maxsize = self.__getInfo(uploader.INFO_FLASH_SIZE)
self.extf_maxsize = self.__getInfo(uploader.INFO_EXTF_SIZE)
try:
self.extf_maxsize = self.__getInfo(uploader.INFO_EXTF_SIZE)
except Exception:
print("Could not get external flash size, assuming 0")
self.extf_maxsize = 0
def dump_board_info(self):
# OTP added in v4: