Skip to content
vpetryaev edited this page Oct 20, 2016 · 1 revision

Working with TFT by SPI require fastest method to communicate with TFT controller. Most of existing SPI libraries using AVR hardware SPI. Unfortunately, ATMega328P (and most AVR MC) haven't transmitter buffering for SPI. But transmitter can buffered using USART in Master SPI Mode (MSPIM).

Rewriting SPI library for MSPIM allows double SPI transfer speed, comparing with Arduino SPI library. In addition, new library allows not only transmit, but also receive data from TFT controller. This allows sprite management without saving all screen content in RAM. RAM used only for small rectangle, hided by sprite. All other background stored only in frame buffer memory inside TFT controller. Library read frame buffer when sprite drawing and moves.

Clone this wiki locally