-
-
Notifications
You must be signed in to change notification settings - Fork 30
board: Add support for UNO Q #210
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
zephyrCommon: Fixed a bug in the interrupt handler acquisition
Why include this commit as part of a PR for support for UNO Q?
Can it be a separate PR of it's own please?
@pillo79 can you send it as a different PR? (and remove from this branch) |
Take into account the analog switch
Use RBIT intrinsic (if available) instead of the slow software reverse. Note that RBIT is at least ~2x faster: Reverse Function Benchmark ========================== Current implementation: 18 ms Optimized implementation: 8 ms Speedup: 2.25x Signed-off-by: iabdalkader <[email protected]>
The main optimization eliminates the double MODER register write when on=true. Previously: MODER &= ~(0xFFFFFF) then MODER |= pin_bits (two writes) Now: MODER = 0 when off, or MODER = pin_bits when on (single write each) Otherwise, the compiler is already doing a pretty good job. Additional improvements: - Remove unused idxToPin() function (was just returning idx) - Remove unused reverse() function - Use direct pin array access and bit shifts for efficiency Signed-off-by: iabdalkader <[email protected]>
this commit can be reverted as soon as the libraries are added to library manager
#203 was already opened a few weeks ago, this commit being included was a leftover from all the rebases during the Uno Q release process. Fixed! |
Thanks Luca! |
No description provided.