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

SX1509: drop i2c modify bits #6684

Merged
merged 2 commits into from
Sep 22, 2024
Merged

Conversation

nefelim4ag
Copy link
Contributor

@nefelim4ag nefelim4ag commented Sep 10, 2024

i2c_modify_bits is tricky and used only in one place where it actually seems overcomplicated.
We do not modify registers in other places, they are reset before setting new bits.
So they can be simplified to i2c_write.

Datasheet: https://cdn.sparkfun.com/datasheets/BreakoutBoards/sx1509.pdf

Thanks.


#6674

According to the datasheet default value is 0000 0000
We do not modify them in other places.

Signed-off-by: Timofey Titovets <[email protected]>
No longer used and niche

Signed-off-by: Timofey Titovets <[email protected]>
@KevinOConnor
Copy link
Collaborator

Thanks. Seems useful to me.

I believe the sx1509 was only used on the duet2 with the duex add-on board. It would be great if someone could confirm everything still works after this change. I'm not sure how many users there are now for that board. Maybe @ReXT3D would know?

-Kevin

@ReXT3D
Copy link

ReXT3D commented Sep 13, 2024

Unfortunately I am unable to comment. I never used the sx1509 and both my Duet2 cards are currently not in active use.

@nefelim4ag nefelim4ag mentioned this pull request Sep 14, 2024
@KevinOConnor KevinOConnor merged commit 8a5801a into Klipper3d:master Sep 22, 2024
1 check passed
@KevinOConnor
Copy link
Collaborator

Thanks.

-Kevin

Misterke pushed a commit to Misterke/klipper that referenced this pull request Nov 1, 2024
* sx1509: drop i2c_modify_bits

According to the datasheet default value is 0000 0000
We do not modify them in other places.

Signed-off-by: Timofey Titovets <[email protected]>

* i2c: drop i2c_modify_bits

No longer used and niche

Signed-off-by: Timofey Titovets <[email protected]>

---------

Signed-off-by: Timofey Titovets <[email protected]>
Co-authored-by: Timofey Titovets <[email protected]>
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.

3 participants