Makerfab TFT7" settings.toml parameter to set screen variant #9634
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
After using settings.toml to deal with the Sunton display board variants I thought the same technique might be used to deal with the Makerfabs MaTouch TFT 7" board which comes in two different screen resolutions (800x480 & 1024x600). Currently we were not initializing the display in board.c because of the variants so instead, the display needed to be initialized using python code.
This update will default to initializing the board at 800x480 (which results in a partially readable display on the 1024x600 variant) but use the 1024x600 settings if the new CIRCUITPY_DISPLAY_WIDTH settings.toml parameter is set to 1024. If an invalid value is entered the display will be initialized using the 800x480 parameters.
I've tested this on the 1024x600 display variant but don't have the 800x480 version.