Bug when drawing lines fast
When FAST_LINE is enabled, color of many pixels will be wrong. Here is the example code:
#include <TFT_ILI9163.h>
TFT_ILI9163 tftDisplay = TFT_ILI9163();
void setup() {
tftDisplay.init();
tftDisplay.setRotation(1);
tftDisplay.fillScreen(TFT_BLACK);
for(int16_t i = 0; i < 128; i++) {
tftDisplay.drawLine(0, 0, 159, i, 0x018E);
}
for(int16_t i = 0; i < 160; i++) {
tftDisplay.drawLine(0, 0, i, 127, 0x018E);
}
}
This example will generate the following image:

It is likely that the SPI clock rate is set too high. What rate are you using?
I am using the default values. Since the system clock is 16 MHz, so the SPI speed should be 4 MHz. The MCU is ATmega328P.
Sorry, that was a daft question. I am so used to folk using my TFT_eSPI library and trying to run displays at 80MHz SPI clock rate!
I suspect the timing optimisation in the library is too tight and thus borderline on failing with some setups. I don't have a test setup to check any changes but I will make some adjustments if you are willing to help experiment with settings.
Sure, I will be glad to help. Also, noticed many warnings (when all compiler warnings are turned on in settings), mostly about unused variables. I can fork the repo and correct this, if you like.
OK, warning correct would be helpful.