Skip to content

add rotation to picoDVI or to adafruit_display_text to use display in portrait mode #9647

Closed
@mrbbp

Description

@mrbbp

there si no way to use a dvi display in portrait mode with picoDVI lib.
The lib support only 320*240 in 8b colordepth or 640*480 in 2b

If we try by inverting size, we received error

Traceback (appels les plus récents en dernier) : Fichier "<stdin>", ligne xx, dans <module> ValueError: height invalide

see this topic

to use in portrait mode, it could be like this

# Adjusted framebuffer dimensions for portrait mode
fb = picodvi.Framebuffer(240, 320,
    clk_dp=board.GP14, clk_dn=board.GP15,
    red_dp=board.GP12, red_dn=board.GP13,
    green_dp=board.GP18, green_dn=board.GP19,
    blue_dp=board.GP16, blue_dn=board.GP17,
    color_depth=8)

# Set rotation to 90 degrees for portrait mode
display = framebufferio.FramebufferDisplay(fb, rotation=90)

an other way could be to add rotationparameter to adafruit_display_text

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions