Skip to content

Add picotool help topics - #342

Open
will-v-pi wants to merge 12 commits into
developfrom
compress-common-opts
Open

Add picotool help topics#342
will-v-pi wants to merge 12 commits into
developfrom
compress-common-opts

Conversation

@will-v-pi

@will-v-pi will-v-pi commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

The device selection options have got quite long, so move them into a separate picotool help device-selection command, rather than appearing in every help output

Also add a family-ids topic to list available family IDs (fixes #305)

Also makes various improvements to the help output.

@kilograham

Copy link
Copy Markdown
Contributor

maybe worth renaming "device selection" at least the heading/docs (not the help option) to indicate that it has other stuff like reboot

Comment thread main.cpp
Comment thread main.cpp
Comment thread README.md Outdated
Comment thread README.md
Comment thread main.cpp
@will-v-pi

Copy link
Copy Markdown
Contributor Author

maybe worth renaming "device selection" at least the heading/docs (not the help option) to indicate that it has other stuff like reboot

I have updated it to "Options for Target Device Selection and Rebooting"

Comment thread README.md
Comment thread gen_help_txt.sh
Comment thread README.md Outdated
@lurch

lurch commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Perhaps the "Show general help or help for a specific command" now ought to say "Show general help, or help for a specific command or topic".

Comment thread main.cpp
Move device selection options into a separate picotool help device-selection command, rather than appearing in every help output

Also add a family-ids topic to list available family IDs (fixes #305)
Add docs for `version` and remove ALLOWED_MISSING_COMMANDS

"Post load actions" -> "Load options"

set/get -> get/set

Fix white-label -s option not showing up

Fix otp permissions docs
gen_help_txt.sh tidyups

Add topic mention to picotool help docs

Missing comma in block devices docs
Fixes things like --family <family_id> appearing on separate lines

Also ensures short and long options are shown in the help output
…tout

Also ensure all lines end in full-stops
Comment thread README.md
otp Commands related to the RP2350 OTP (One-Time-Programmable) Memory
partition Commands related to RP2350 Partition Tables.
uf2 Commands related to UF2 creation and status.
otp Commands related to the RP2350 OTP (One-Time-Programmable) Memory.

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.

Suggested change
otp Commands related to the RP2350 OTP (One-Time-Programmable) Memory.
otp Commands related to the RP2350 OTP (One-Time-Programmable) memory.

Comment thread README.md

Use "picotool help <cmd>" for more info
TOPICS:
device-selection Options for Target Device Selection and Rebooting

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.

The selection of Capital letters here feels a Bit Random? 🤔

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It’s just title case

Comment thread README.md
The normal output is this format:
```text
$ picotool version
picotool v2.3.0 (Linux, GNU-12.2.0, Release)

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.

Probably not worth it, but I guess all these v2.3.0 versions could be updated to v2.3.1 ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I’ll merge in develop so they get updated, otherwise the CI readme check will fail

Comment thread README.md
2.3.0
```

Or with an incompatible version (e.g. 2.4.0 with version 2.3.0), it will exit with error code `ERROR_INCOMPATIBLE` (-3):

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.

It earlier says "to check a newer picotool is backwards compatible with an older version", so perhaps it doesn't make sense to try checking against a not-yet-released picotool version, and would be better to check against an older version that picotool 2.3.0 isn't backwards-compatible with?

Comment thread README.md
Comment on lines +258 to +259
-s, --set <key> <value>
Set config variable name to new value

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.

Outside the scope of this PR, but if picotool config allows you to set the value of a particular config key, it'd probably also be useful if it allowed you to get the value of a single config key?

Comment thread README.md
Specify the load address when comparing with a BIN file
<offset>
Load offset (memory address; default 0x10000000)
-r, --range <from> <to>

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.

Why does the help-text for the erase command below not also use this new single-line -r, --range <from> <to> format?

Comment thread README.md
Specify the OTP page storing the AES key (IV salt is stored on the next page)
<page>
OTP page (default 29)
--otp-key-page <page>

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.

Does this command fail if given an otp-key-page but not an otp JSON filename? (And similarly does it fail if given an otp JSON filename but not an otp-key-page?)

And presumably the --sign command fails if not given a <signing_key>?

Hmm, is the <signing_key> option of the encrypt command the same thing as the <key> option of the seal command? (If they are, perhaps it makes sense to rename seal's option for consistency?)

Comment thread README.md
Specify file type (elf) explicitly, ignoring file extension
Partition Table Options
--sign <keyfile>
The file name

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.

Should "The file name" here be "Signing Key file (.pem)" ?

Hmm, should the <bootloader> option's "The file name" text be clarified too?

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.

Improve discoverability of family names and improve the user experience in related error messages

3 participants