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

Support for 240x280 pixel display... #11

Open
ctschach opened this issue Jan 30, 2024 · 1 comment
Open

Support for 240x280 pixel display... #11

ctschach opened this issue Jan 30, 2024 · 1 comment

Comments

@ctschach
Copy link

What is needed to support a different screen resolution?

I have a display that is using 240x280 pixels which I bought from here:

https://www.azdelivery.de/products/1-69-zoll-tft-display

I would love to implement this as long as I get some initial ideas how to do it....

@tghturner
Copy link

I have a display with those dimensions on the back. It turns out it is actually 240x300!
Anyway to add the resolution just add it to the list and add the _DISPLAY_240x300 block. Adapt as required

Supported displays (physical width, physical height, rotation table)

_SUPPORTED_DISPLAYS = (
(240, 320, _DISPLAY_240x320),
(240, 240, _DISPLAY_240x240),
(240, 300, _DISPLAY_240x300), # New Display Mode
(135, 240, _DISPLAY_135x240),
(128, 128, _DISPLAY_128x128),
)

#Rotation table
_DISPLAY_240x300 = (
(0x00, 240, 300, 0, 0, False), # Portrait
(0x60, 300, 240, 0, 0, False), # Landscape
(0xc0, 240, 300, 0, 40, False), # Inverted Portrait
(0xa0, 300, 240, 40, 0, False) # Inverted Landscape
)

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

No branches or pull requests

2 participants