-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
support spi for sn74hc595 #5491
Conversation
@notsonominal Did this one also work gor you? |
Works great both as SPI and non-SPI on Shelly pro and Shelly plus models I tested. |
I just made some (untested) changes to the code to clean it up a bit and truly split spi vs gpio right from codegen. Please make sure they work for you and let me know |
I can confirm it compiles for me. Nice rework. @notsonominal could you please retest on your side? I do not have this device. |
yeah, still works both as spi and no spi 👍 |
clean and run gets past it though, and both still works |
I can take a look at the warning this evening. Can you dm your config (just in case)? |
@notsonominal - I am not able to reproduce the warning you are getting. So could you open an issue and attach your configuration? It might be depending on the framework/device... |
What does this implement/fix?
Support using SPI for the sn74hc595. This is required when other SPI devices are in the same bus such as by the Shelly Pro 2PM.
Types of changes
Related issue or feature (if applicable): NA
Pull request in esphome-docs with documentation (if applicable): esphome/esphome-docs#3341
Test Environment
Example entry for
config.yaml
:When using the SPI the following can be used:
When not using the SPI, the same previous schema works:
Checklist:
tests/
folder).If user exposed functionality or configuration variables are added/changed: