-
Notifications
You must be signed in to change notification settings - Fork 17.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AP_Logger: Add enum information to VER log message metadata #26308
AP_Logger: Add enum information to VER log message metadata #26308
Conversation
Could we get a PR for just the message documentation without enumerations, please? That would give immediate value. We're already a little over-enthusiastic about what we're parsing out of the C++ code; it took a lot of convincing to even allow parsing out of enum-classes! Parsing out |
Sure no problem - small steps :-).... New PR created #26311. |
Merged the other one - rebase, please? |
b00a634
to
bc91b6e
Compare
I hadn't thought I was opening up a controversial topic! Sorry for that :-).... I can appreciate that parsing the source code in this way may lead to cases where compiler-legitimate code changes end up breaking this parsing - and that is probably even more plausible with #defines. More of a nice to have to no rush on having the debate, and if it is preferred to reject, no worries! One idea instead could be to use add to the field description something like "See HAL_BOARD_* in AP_HAL_Boards.h", so that at least users have some clue on how to know what any given value means. |
@shancock884 needs a rebase. Marking for DevCall to see if we're OK with this additional parsing. |
d05476d
to
5fe8452
Compare
Rebase done, and checked that output is as expected. |
5fe8452
to
fef05ce
Compare
Maybe we have it somewhere, and not a blocker for this PR. But it would be great to document the various |
The aim of this PR is to add help text for the VER and FILE log messages (linked to issue #26088).
Implemented by adding the relevant comment tags into AP_Logger.cpp
As well as just adding the field descriptions, I wanted to include the enumeration information for the BT, BST and BU fields of the VER message. As there are sets of #defines and not actual enums, I made the following updates:
Tested by running parse.py for each vehicle type, and checking the output.
As example, this is the output for the VER message in the .rst output file used to create the wiki page (truncated here to save space):