@powersoft Maybe you find it interesting to know that there is a way of compiling a picture into your code so that you do not need an SD-card. This could make your solution more simple.
To do:
Download the UTFT-library from Rinky Dink Electronics (http://www.rinkydinkelectronics.com/library.php?id=51)
Extract the download and use the Tools\Imageconverter565.exe to convert the image to a .c file (select AVR board)
Open the .c file and change the line '#include <avr/pgmspace.h>' into '#include<pgmspace.h>'
Insert the following lines in the file (the values should be the same as the image, 320x240 is max for M5Stack):
const uint16_t imageWidth = 320;
const uint16_t imageHeight = 240;
Rename the .c file into .h (e.g. logo.c into logo.h) and place the file in the folder where the .ino-file for your project is
In your Arduino-program add the following line in the top (or the other filename you have chosen)
#include <M5Stack.h>
#include "logo.h"
In your Arduino-program add the following line in the 'setup'-function:
M5.Lcd.setSwapBytes(true);
In your Arduino-program add the following line in the place where you want to show the image:
M5.Lcd.pushImage(0, 0, logoWidth, logoHeight, logo);
I have included a link to a small demo-file on the following page:
https://info.kosternet.nl/doku.php?id=publiek:m5stack