Skip to content

Add load support for universal binaries - #349

Open
will-v-pi wants to merge 6 commits into
developfrom
universal-load
Open

Add load support for universal binaries#349
will-v-pi wants to merge 6 commits into
developfrom
universal-load

Conversation

@will-v-pi

Copy link
Copy Markdown
Contributor

This adds support to picotool load for loading universal binaries, and other multi-family UF2s

The existing --family flag can be used to select which family to load from the UF2 - otherwise it picks using the partition table, or based on the supported families for the device for RP2040 or SRAM binaries (no partition table)

Also fixes picotool info and other command support for 2.3.0 universal binaries, which have rearranged blocks that picotool was handling incorrectly

Fixes #344

Also adds supported family IDs to models, used to check if family is supported for SRAM loads (and RP2040 flash loads)

This fixes picotool load for the universal binaries
New ones split the last RP2040 block after all the RP2350 blocks to prevent Windows errors, so fix build_rmap_uf2 to handle that
Add robustness for invalid UF2 files

Allow loading BIN/ELF files into SRAM/RP2040 regardless of the guessed family ID, to match prior behaviour
Now it also ignores UF2 compatibility checks for RP2040 and SRAM binaries too
Comment thread main.cpp Outdated
Comment thread main.cpp Outdated
Comment thread README.md
@@ -314,7 +314,7 @@ SYNOPSIS:
OPTIONS:
Post load actions

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess some of these aren't post-load options 😉

Comment thread README.md
Post load actions
--ignore-partitions
When writing flash data, ignore the partition table and write to absolute space
Ignore the partition table, or whether the family ID is compatible with the device

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would there ever be a use-case for this being a separate --ignore-family-ids option rather than shoe-horning this functionality into --ignore-partitions?

If not, perhaps this wording is slightly clearer?

Suggested change
Ignore the partition table, or whether the family ID is compatible with the device
Ignore the partition table, and ignore family ID compatibility

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants