Fix WAIT GPIO n for n > 32 and when using gpio_base = 16#2265
Merged
kilograham merged 1 commit intodevelopfrom Feb 14, 2025
Merged
Fix WAIT GPIO n for n > 32 and when using gpio_base = 16#2265kilograham merged 1 commit intodevelopfrom
WAIT GPIO n for n > 32 and when using gpio_base = 16#2265kilograham merged 1 commit intodevelopfrom
Conversation
Contributor
Author
|
fixes #2141 |
WAIT GPIO n for n > 32 and when using gpio_base = 16
- fix bug: pioasm was spilling bit 5 of arg2 into arg1 - make pio_add_program flip bit 5 of a WAIT GPIO instruction if gpio_base is 16 Note: pioasm will encode only the bits 4-0 of arg2 (the GPIO number), however it does indicate whether 0-15 means 0-15 or 32-47. This can only be fixed up when loading the program, and indeed once the GPIO base is known. pio_can_add_program and friends already detected the cases where this was impossible
8f25148 to
69ae917
Compare
peterharperuk
approved these changes
Feb 14, 2025
Contributor
peterharperuk
left a comment
There was a problem hiding this comment.
Ok. After staring at this for awhile it looks good. We really should have an example of using this. Any suggestions?
will-v-pi
pushed a commit
to will-v-pi/pico-sdk
that referenced
this pull request
Mar 20, 2025
…pi#2265) - fix bug: pioasm was spilling bit 5 of arg2 into arg1 - make pio_add_program flip bit 5 of a WAIT GPIO instruction if gpio_base is 16 Note: pioasm will encode only the bits 4-0 of arg2 (the GPIO number), however it does indicate whether 0-15 means 0-15 or 32-47. This can only be fixed up when loading the program, and indeed once the GPIO base is known. pio_can_add_program and friends already detected the cases where this was impossible
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.
Note: pioasm will encode only the bits 4-0 of arg2 (the GPIO number), however it does indicate whether 0-15 means 0-15 or 32-47. This can only be fixed up when loading the program, and indeed once the GPIO base is known. pio_can_add_program and friends already detected the cases where this was impossible