mirror of
https://github.com/esphome/esphome.git
synced 2025-04-16 07:40:29 +01:00
add support for merged image
This commit is contained in:
parent
c1be5c4680
commit
3334ce5058
@ -118,6 +118,7 @@ def get_download_types(storage_json):
|
||||
UF2_PATH = "zephyr/zephyr.uf2"
|
||||
DFU_PATH = "firmware.zip"
|
||||
HEX_PATH = "zephyr/zephyr.hex"
|
||||
HEX_MERGED_PATH = "zephyr/merged.hex"
|
||||
build_dir = Path(storage_json.firmware_bin_path).parent
|
||||
if (build_dir / UF2_PATH).is_file():
|
||||
types = [
|
||||
@ -139,7 +140,9 @@ def get_download_types(storage_json):
|
||||
{
|
||||
"title": "HEX package",
|
||||
"description": "For flashing via pyocd using SWD.",
|
||||
"file": HEX_PATH,
|
||||
"file": HEX_MERGED_PATH
|
||||
if (build_dir / HEX_MERGED_PATH).is_file()
|
||||
else HEX_PATH,
|
||||
"download": f"{storage_json.name}.hex",
|
||||
},
|
||||
]
|
||||
|
Loading…
x
Reference in New Issue
Block a user