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

Implement pulldown and pullup on input #35

Merged
merged 3 commits into from
Dec 28, 2018
Merged

Conversation

simonsso
Copy link
Contributor

@simonsso simonsso commented Dec 8, 2018

It looked like this was prepared already, I needed to enable a pull up on my gpio so I implemented it.
Pull up is verified on nrf52dk button1 - 4

The pull-down is still untested it is however symmetrical.

Should the function names be different?

Please enjoy.

@jamesmunns
Copy link
Member

Hey @simonsso, thanks for the contribution!

We are about to wrap up the v0.6.0 release, once that is wrapped I'll try to get this merged for you!

@simonsso
Copy link
Contributor Author

simonsso commented Dec 11, 2018

Thanks, Is there a better base line I could base this and further patches on to minimize extra merge conflicts on?

@simonsso
Copy link
Contributor Author

Rebased

@@ -12,9 +12,9 @@ pub struct Input<MODE> {
/// Floating input (type state)
pub struct Floating;
// /// Pulled down input (type state)
// pub struct PullDown;
pub struct PullDown;
// /// Pulled up input (type state)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you mind removing these double comments? (Lines 14 and 16)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

By remove I mean // /// ... => /// ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@jamesmunns
Copy link
Member

Overall looks good, thank you! If you could remove the comments, and CI passes, I'll merge this shortly!

Removed uncommended comment
Copy link
Member

@jamesmunns jamesmunns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I'll merge once CI passes.

@jamesmunns jamesmunns merged commit 25550fc into nrf-rs:master Dec 28, 2018
@simonsso simonsso deleted the gpio branch December 29, 2018 03:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants