Close

you can write half as much data to ili9341 display and have it look great!

A project log for spi write up to 64 colors at a time on Arduino!

amg8833 equivilent sensor thermal cam is a perfect example of how to write faster with spi lcd displays. 128x128 sample fast on Arduino.

jamesdanielvjamesdanielv 10/17/2018 at 21:400 Comments

the screen resolution of the ili9341 is 4x what the st77xx display i also support is. i have done optimizations that speed up ili9341 spi performance

here is how long it takes to write a solid 30x32 block (creates a near square pixel on screen in 8x8 mode, on 320x240 display)

default driver is on right side for timing in microseconds, spi optimizations is on the left side (we do calculations  or data manipulation while spi is writing, instead of stopping and waiting for spi to complete.

but it gets even better. 

if you only write every other line (you send a lot of data, and write every other line, you get better performance. not as huge as before, but it makes frames per second higher. up to 64 of these pixel blocks are written every second (buffered modes reduce this about 50%)

and here is the image results of just writing every other line on screen

you really can only tell if your eyes are within 6 inches of display.  it might be touch screen plastic over the display or the display itself, it diffuses the light, so the gap between lines is minimal.

here is some data  without processing overhead (300us) to show best frame rates possible with defaults and so far.

default driver: 4300us per block= 4300x64=275200 or 1000000=3.6 fps best case

spi optimized :2850us per block= 2850x64=182400 or 1000000/182400=5.48 fps * 2 (just over 10fps buffered)

this mode: spi optimized :2360us per block= 2360x64=151040 or 1000000/151040=6.62 fps * 2

remember not every pixel updates or changes at once. using buffers 2x-5x frame rates.

default driver does have buffering but only on arm cortex.

i think i can also make every other line method better by making pixels area larger. the more in line writes at a time the fewer set pixel overhead commands are used. to get every other line i had to increase command overhead for each line start.

video below is in 16x16 sub sample mode for the ili9341 display. i still need to modify drivers to do more resolution (little overhead) most of overhead is display writes. the st77xx display can do 64x64 subsample well.

Discussions