Commit deca190
ili9341: add EnableTEOutput to be able to sync drawing with VSYNC
Many displays don't have the TE pin exposed. But those that do have the
pin (for example, the PyPortal) can use it to synchronize writing a new
image to the display. When implemented correctly, tearing can be avoided
entirely.
This commit also changes the LCD refresh direction to either
top-to-bottom or left-to-right depending on the rotation. Previously it
might refresh from right-to-left or bottom-to-top. This has little
impact on code that doesn't use the TE line, but code that does now only
needs to worry about two cases (top-to-bottom and left-to-right) instead
of four.
(Unfortunately, it appears that the hardware doesn't support changing
the major LCD refresh order so code that wants to do tear-free rendering
still needs to care about these two cases).1 parent 184dff9 commit deca190
2 files changed
+19
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
160 | 160 | | |
161 | 161 | | |
162 | 162 | | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
163 | 175 | | |
164 | 176 | | |
165 | 177 | | |
| |||
287 | 299 | | |
288 | 300 | | |
289 | 301 | | |
290 | | - | |
| 302 | + | |
291 | 303 | | |
292 | | - | |
| 304 | + | |
293 | 305 | | |
294 | 306 | | |
295 | 307 | | |
296 | | - | |
| 308 | + | |
297 | 309 | | |
298 | | - | |
| 310 | + | |
299 | 311 | | |
300 | | - | |
| 312 | + | |
301 | 313 | | |
302 | 314 | | |
303 | 315 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
41 | 41 | | |
42 | 42 | | |
43 | 43 | | |
| 44 | + | |
| 45 | + | |
44 | 46 | | |
45 | 47 | | |
46 | 48 | | |
| |||
0 commit comments