drivers/periph/gpio(_ll): Enhance and fix the documentation#21538
Merged
crasbe merged 2 commits intoRIOT-OS:masterfrom Jun 4, 2025
Merged
drivers/periph/gpio(_ll): Enhance and fix the documentation#21538crasbe merged 2 commits intoRIOT-OS:masterfrom
crasbe merged 2 commits intoRIOT-OS:masterfrom
Conversation
maribu
approved these changes
Jun 4, 2025
Member
|
Only needs a rebase to get in |
Contributor
Author
|
Doxygen did not recognize the function references in the |
Contributor
Author
|
Now I'm happy. Can I squash? |
Member
|
Yes, sure |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contribution description
This PR aims to add a little bit of documentation about the
gpio_get_pin_numandgpio_get_port, which are not really documented but incredibly important if you want to use a function likegpio_ll_init.The issue first came up during the development of #21332, because the nRF52 microcontrollers don't actually distinguish between port P0 and P1 internally, there are just 32 registers for the pins and P1 has the fifth bit set in the pin number (Mask 0x1F).
Therefore, if you try to initialize a P1 pin with
gpio_ll_initand just naively use numbers for the pins, you will actually modify the pins on P0.It just came up in our seminar again, therefore I decided to finally add some documentation.
Also I fixed the documentation for
gpio_irq_enable, which was accidentally rendered as a code block instead of text. See: https://www.doxygen.nl/manual/markdown.html#md_codeblockTesting procedure
Make sure the documentation still looks good.
Issues/PRs references
None.