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 MODE_NO_CS to SPI devices #162

Open
dbartussek opened this issue Oct 18, 2024 · 1 comment
Open

Add support for MODE_NO_CS to SPI devices #162

dbartussek opened this issue Oct 18, 2024 · 1 comment
Labels

Comments

@dbartussek
Copy link

I am communicating with a device that needs a few milliseconds to register that CS has been asserted and must therefore manually control the CS pin.

In Python, this can be achieved with spidev by setting the no_cs member on an SpiDev instance to true and manually driving the CS pin.
I've now tried to port this code to Rust but found that the MODE_NO_CS flag exists as a constant, but it isn't exposed.

@golemparts
Copy link
Owner

When I initially wrote the SPI code, SPI_NO_CS wasn't fully supported by either the underlying drivers or hardware. See this section of the documentation for a possible workaround.

Since it's been a while since I last checked, it's possible support for NO_CS has been added in the mean time. On which Pi device were you able to get it to work in Python?

@golemparts golemparts added the spi label Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants