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

parl_io uses InputConnection instead of PeripheralInput #2658

Closed
Tracked by #2492
bjoernQ opened this issue Dec 2, 2024 · 1 comment · Fixed by #2692
Closed
Tracked by #2492

parl_io uses InputConnection instead of PeripheralInput #2658

bjoernQ opened this issue Dec 2, 2024 · 1 comment · Fixed by #2692
Labels

Comments

@bjoernQ
Copy link
Contributor

bjoernQ commented Dec 2, 2024

see #2492 (comment)

If a driver requires pins, those pins must be configured using

fn with_signal_name(self, pin: impl Peripheral<P = InputConnection> + 'd) -> Self)
or
fn with_signal_name(self, pin: impl Peripheral<P = OutputConnection> + 'd) -> Self)

We currently only do that for parl_io and the doc for InputConnection say:

This is mainly intended for internal use, but it can be used to connect peripherals within the MCU without external hardware.

Given the comment I'd say let's not mark this (InputConnection) as stable to reduce the stable API surface but the advice in the API guidelines suggest we shouldn't - however there is a mismatch between the guidelines and the API docs (and the reality of existing drivers). Similarly OutputConnection (Bjoern).

@github-project-automation github-project-automation bot moved this to Todo in esp-rs Dec 2, 2024
@playfulFence playfulFence mentioned this issue Dec 2, 2024
34 tasks
@MabezDev MabezDev changed the title API guidelines discrepancy parl_io uses InputConnection instead of PeripheralInput Dec 4, 2024
@bugadani
Copy link
Contributor

bugadani commented Dec 6, 2024

I'm trying to find where exactly this is a problem, but all the public APIs I see use PeripheralInput and PeripheralOutput. Internally these are converted into Input/OutputConnection but that should be fine.

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

Successfully merging a pull request may close this issue.

2 participants