-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Rp2040 countio #4254
Rp2040 countio #4254
Conversation
dddb4e5
to
379f454
Compare
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.
Thanks for this! The logic looks good except for storing the object. It won't work with multiple counters running at once. Suggestions inline.
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.
Thanks for the update! It looks good. However, I thought of another case that probably needs to be handled. We likely need to set one of the globals from PWMOut so that it doesn't allocate to the channel A pin at the same time. Could you try making a countio and then making a PWMOut on the other pin? It should error. Thanks!
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.
Looks good! Thank you!
Adding countio to RP2040. This build uses the PWM IRQ that does not seem in use in the PWM module. If the PWM module started to use it there could be a conflict.