diff --git a/Tools/scripts/uploader.py b/Tools/scripts/uploader.py index fef06ae30e..b34759a2d8 100755 --- a/Tools/scripts/uploader.py +++ b/Tools/scripts/uploader.py @@ -682,9 +682,6 @@ class uploader(object): print("Unsupported bootloader protocol %d" % self.bl_rev) raise RuntimeError("Bootloader protocol mismatch") - 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) if self.no_extf: self.extf_maxsize = 0 else: @@ -693,6 +690,11 @@ class uploader(object): except Exception: print("Could not get external flash size, assuming 0") self.extf_maxsize = 0 + self.__sync() + + 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) def dump_board_info(self): # OTP added in v4: