diff --git a/tools/ci/python_packages/ttfw_idf/IDFDUT.py b/tools/ci/python_packages/ttfw_idf/IDFDUT.py index 5828eaabdb..ed5268985b 100644 --- a/tools/ci/python_packages/ttfw_idf/IDFDUT.py +++ b/tools/ci/python_packages/ttfw_idf/IDFDUT.py @@ -391,13 +391,14 @@ class IDFDUT(DUT.SerialDUT): for (_, f) in encrypt_offs_files: f.close() - def bootloader_flash(self): + def bootloader_flash(self, binary_path=None): """ download bootloader. :return: None """ - bootloader_path = os.path.join(self.app.binary_path, 'bootloader', 'bootloader.bin') + binary_path = self.app.binary_path if binary_path is None else binary_path + bootloader_path = os.path.join(binary_path, 'bootloader', 'bootloader.bin') offs = int(self.app.get_sdkconfig()['CONFIG_BOOTLOADER_OFFSET_IN_FLASH'], 0) flash_files = [(offs, bootloader_path)] self.write_flash(flash_files)