hiram
New Member
Posts: 7
|
Post by hiram on Apr 7, 2015 14:30:10 GMT -8
How to know if file exist in the microSD, if exist show the file in the screen,
I use this code:
if (GD.load(filename) == true) { Serial.println("Picture exist."); GD.resume(); GD.Clear(); GD.ClearColorRGB(15,115,180); GD.cmd_loadimage(0, 0); GD.load(filename); GD.Clear(); GD.Begin(BITMAPS);; GD.Vertex2ii(190, 50); GD.swap(); } else { Serial.println("Picture doesn't exist."); return; }
When the sentence is true the picture doesn't show in the screen, when is false operates correctly.
|
|