samples/cfb/display flickers with SSD1306 #25161
Labels
area: Display
bug
The issue is a bug, or the PR is fixing a bug
priority: low
Low impact/importance bug
Describe the bug
When running the example for the SSD1306, the display flickers between "012345" shown, to blank.
The following code in the example sets the font to the largest available (in my case, height of 32)
In the console output, it prints:
which I assume means:
x_res
= x resolution, 128 pixelsy_res
= y resolution, 32 pixelsppt
= pixels per tile, 8 pixels (tiles are vertical only, so it is a 1x8 pixel tile)rows
= number of tile rows, 4 (= y_res/ppt)cols
= number of tile cols, 128However in the main loop it then runs a for loop for each tile row, not character row:
Should it actually be something like:
Although this causes flickering if there is more than one character row (in my example,
font_height=16
), as the display willSo row 0 flickers between having text and being blank, and row 1 flickers between wrapped characters and written characters.
I think the actual intention of this example is to do something like:
Which just prints that text on every line (or as much as possible). This seems much more sensible than the existing sample.
I can create a PR for this last case, I'm just looking for some guidance as to what the sample is actually supposed to do.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The display should not flicker, or it should at least be documented that this is the expected behaviour (although I'm not sure how useful that is as an example).
Screenshots or console output
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: