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

Open
maruel opened this issue Sep 20, 2023 · 0 comments
Open

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

No branches or pull requests

1 participant