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

Add support for reading back values of ON/OFF states #12

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

UhhhWaitWhat
Copy link

@UhhhWaitWhat UhhhWaitWhat commented Jan 7, 2024

Hi, first off thank you for your library it is very useful.
While building something with it I realised it might be helpful to read back the current state of the ON/OFF states. So this PR adds this functionality to the library. I added a couple methods matching the setters and also added tests for them.

I do have pretty much no experience with the bitfiddly bits of rust programming though, so if anything needs improvement I'll gladly adjust the code :)

Copy link
Owner

@eldruin eldruin left a comment

Choose a reason for hiding this comment

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

Thank you for this work!
Sorry, let's do this after #13 since that already has very substantial changes and adding this again once that is merged should be simple.

src/channels.rs Outdated Show resolved Hide resolved
src/channels.rs Outdated Show resolved Hide resolved
@UhhhWaitWhat
Copy link
Author

Sure, I'll rework/rewrite this PR once #13 is merged :)

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