Is SPI just "slow"?
Is SPI just "slow"?
Hi, hope this post is fine in regard of rule 2.
Currently doing some fun stuff with an Arduino and have it hooked up to an 128x160px and communicate with it over SPI. If i color in all 20480 pixels it takes about 2 seconds to be done and i can watch the rows change one after another.
I was wondering if there are some tricks to speed this process up a bit or does it really just come down to minimizing the pixels to be changed?
The module im using is this one: https://www.waveshare.com/wiki/1.8inch_LCD_Module
Here is also my current code if anybody cares to take a look, even though i just rewrote the example code more or less so i would understand it. https://codeberg.org/bvoigtlaender/open-phone/src/branch/main
EDIT: Thanks to jeinzi, nickwitha_k and cmnybo I have managed to bring the rendering time down from 2142ms to 80ms
- write directly to registers keep in mind that the pin is different when using that method 2142ms > 1912ms
- write bigger chunks of data 1912ms > 272ms
- set spi clock 272ms > 80ms