-
Notifications
You must be signed in to change notification settings - Fork 14
Implementing dynamic databus registry #99
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
base: i8080
Are you sure you want to change the base?
Conversation
* Implement i80 bus for ili9xxx displays * clang-tidy * yamllint * Fix spi_device test --------- Co-authored-by: clydebarrow <[email protected]>
- allow dynamicly add new byte_busses via esphome's registry() method. And makes it possible to detach the ili9xxx from the different databus chooses - make transactions nestable so you can call multiple times begin_transaction and end it - and write_component() inline methods.
- remove unneeded code - renamed write_cmd_data to write_command i80: - renamed i80Client to i80ByteBus conform SPIByteBus - tried to making running - ERROR: ID esp32_esp32internalgpiopin_2 is already registered (NOT FIXED) - allowing to be used in arduino setup. - save rd_pin SPI: - moving creation of SPIClient inside c++ ili9xxx: - add missing await
- allow to change default databus via callback function - adding final_validation option - restore part of the I80 and SPI configuration settings - update list of models with info about screensize, available data busses and if esp8266 is supported.
|
Okay this is what i wanted to do for the PR i was working on. |
|
Just started looking at this. Lots of CI checks are failing. What are all these in ili9xxx/display.py? These obviously refer to bus names, but should be constants, not literal strings: The values defined in ili9xxx/display.py in the MODELS dict should be either dicts or classes. References like Compiling existing yamls fails with errors:
The "16bit_data" spi type should be removed - that's not a variation on the bus, it's a variation in how data is transferred for a specific peripheral, and there is no way of knowing in advance how that should be handled. As discussed before, there is no purpose in allowing multiple more to come... |
Thanks.
Not sure where they coming from but those i checked did not seem related to my changes.
Those are the busses the display controller can handle. This does not mean that we support them.
I agree and i have modified those now.
Oww i did not read your suggestion here correct. At the moment i created some constant's defining what is what. But i think we should use the Registry solution here as well. I already implemented it in my display_driver and can implement it here as well. But can this wait until this our PR is merged?
Could you show the display part of your yaml so i can see what did happen?
Oeps of cource that should have been false.
Sorry, that is your opinion. I disagree, i have used many communication packages in the past from different vendors, that worked this way. As i said on Discord. when we let the display driver handle the opening and closing of the transaction. and remove it in the "send_command" future then we do not need to nest here.
I cant wait to see what you find more 🤞🏼 Sadly i'm not able to update this per anymore, i will send you the changes via discord. |
What does this implement/fix?
This PR enables us to dynamically add more databus drivers when needed.
It is very easy to implement.
Types of changes
Related issue or feature (if applicable): fixes
Pull request in esphome-docs with documentation (if applicable): esphome/esphome-docs#
Test Environment
Example entry for
config.yaml:# Example config.yamlChecklist:
tests/folder).If user exposed functionality or configuration variables are added/changed: