Hi, recently I purchased a TFT touchscreen from Elegoo, similar to Adafruit.
Since this library don't have a function to show bitmaps without SD card, I'm trying to have my own function, but I can't do it works. The code I have written is this:
#include <Elegoo_TFTLCD.h> // Libreria para visualización
#include "logo.h"
int const LCD_CS = A3; // Definimos los pines del LCD
int const LCD_RS = A2; // para poder visualizar elementos graficos
int const LCD_WR = A1;
int const LCD_RD = A0;
int const LCD_RESET = A4;
Elegoo_TFTLCD objetoTFT(LCD_CS, LCD_RS, LCD_WR, LCD_RD, LCD_RESET);
void bitmap(int pos_x, int pos_y, int c, int r, const unsigned char imagen[]){ //
int contador = 0;
for(int i=0; i<r; i++){
for(int j=0; j<c; j++){
objetoTFT.drawPixel(j, i, imagen[contador++]);
}
}
}
void setup() {
pinMode(13, OUTPUT);
objetoTFT.begin(0x9341);
objetoTFT.setRotation(1);
objetoTFT.fillScreen(0XFFFF);
Serial.begin(9600);
}
void loop() {
bitmap(0, 0, 200, 150, logo); // my logo is 200x150 pixels, origin x0,y0
delay(50000);
}
I've used an online web to convert the image, but I don't know if the format is right, or if my function must work as it do.
Any help please?

