Skip to content

Commit 3688b7b

Browse files
committed
Allow custom offsets for bootloader and partitions in ESP-IDF
Issue #11
1 parent 1c76b1b commit 3688b7b

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

builder/frameworks/espidf.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1065,8 +1065,15 @@ def _skip_prj_source_files(node):
10651065
LINKFLAGS=extra_flags,
10661066
LIBS=libs,
10671067
FLASH_EXTRA_IMAGES=[
1068-
("0x1000", os.path.join("$BUILD_DIR", "bootloader.bin")),
1069-
("0x8000", os.path.join("$BUILD_DIR", "partitions.bin")),
1068+
(
1069+
board.get("upload.bootloader_offset", "0x1000"),
1070+
os.path.join("$BUILD_DIR", "bootloader.bin")
1071+
),
1072+
(
1073+
board.get("upload.partition_table_offset", hex(
1074+
sdk_config.get("PARTITION_TABLE_OFFSET", 0x8000))),
1075+
os.path.join("$BUILD_DIR", "partitions.bin")
1076+
),
10701077
],
10711078
)
10721079

0 commit comments

Comments
 (0)