Skip to content
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

gpio: add Group interface, to act on multiple GPIO as a single transaction #30

Closed
maruel opened this issue Sep 20, 2023 · 0 comments · Fixed by #43
Closed

gpio: add Group interface, to act on multiple GPIO as a single transaction #30

maruel opened this issue Sep 20, 2023 · 0 comments · Fixed by #43

Comments

@maruel
Copy link
Member

maruel commented Sep 20, 2023

Ported from google/periph#372.

Let's aim to have at least an idea how a gpio.Group would look like. A Group would be a logical group, not a physical one. To clarify, we're not talking about GPIOs grouped together on a header, I'm talking about GPIOs that are on the same controller thus can be acted on upon as a transaction. See the previous comment for precedents.

My thinking at the moment is to:

  • Add gpio.Group interface, listing its owned pins.
  • Add to interface gpio.Pin a new method .Group().

The interface Group would contain the transactional operations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

1 participant