Hello,
I'm trying to display some bmp image from SD card.
So I'm using these #include <LCDWIKI_GUI.h>
#include <LCDWIKI_KBV.h> libraries.
for these libraries when I execute the example images its working.
But if I convert an image and execute it. This code always gives me error:
if(!analysis_bpm_header(bmp_file))
{
my_lcd.Set_Text_Back_colour(BLUE);
my_lcd.Set_Text_colour(WHITE);
my_lcd.Set_Text_Size(1);
my_lcd.Print_String("bad bmp picture!",0,0);
return;
}
So I always getting "bad bmp picture" error.
And I'm using Image2Lcd v2.9
Actually it is possible that I'm not using converter correctly.
If you can help me. I would be pleasure.
Please post a link to the actual display that you bought.
Please quote the library example by name.
Please attach the actual image you want to display. e.g. .BMP, .JPG, .PNG, ...
Any format that will work on your PC.
Please post a link to your Image2Lcd v2.9
It sounds like a very old version.
David.
TFT Display which is I bought attached below.
http://www.lcdwiki.com/3.5inch_Arduino_Display-Mega2560#Program_Download
In this website find "Program Download" section.
I'm using that file for programming but first you should find this file:
[3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Install libraries](http://3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.01-DemoDemo_Arduino_Mega2560Install libraries)
So you can not add these library from "add .ZIP library"
You should copy these libraries with yourself.
I'm using "show_bmp_picture" Arduino code.
It is working correctly if I copy example .BMP images to SD Card(But images names should be in sequence and start from 01 to 02,03 .. like this.)
In this code there is a 2 Converter file address is below:
3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\7-Character&Picture_Molding_Tool
And these converter names are:
1- Img2Lcd (v2.9)
2-PCtoLCD2002 (this looks very old so I did not use it.)
And Example images address below:
3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Example\Example_06_show_bmp_picture\show_bmp_picture
Or 3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Example\Example_06_show_bmp_picture\picture
Note:
Only First blue one is link others are files address in your computer. Such as:
C:\USER\DESKTOP\File\File... etc.
I'm giving you this address just for itself before ones like what I wrote above are changes from computer to computer.
None of the links work for me.
Please can you edit all of your links. And test each one to prove that you can access them.
David.
TFT Display which is I bought attached below.
http://www.lcdwiki.com/3.5inch_Arduino_Display-Mega2560#Program_Download
In this website find "Program Download" section.
I'm using that file for programming but first you should find this file:
[3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Install libraries](http://3.5inch_arduino_mega2560_16bit_module_ili9486_mar3513_v1.01-demodemo_arduino_mega2560install libraries/)
So you can not add these library from "add .ZIP library"
You should copy these libraries with yourself.
I'm using "show_bmp_picture" Arduino code.
It is working correctly if I copy example .BMP images to SD Card(But images names should be in sequence and start from 01 to 02,03 .. like this.)
In this code there is a 2 Converter file address is below:
3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\7-Character&Picture_Molding_Tool
And these converter names are:
1- Img2Lcd (v2.9)
2-PCtoLCD2002 (this looks very old so I did not use it.)
And Example images address below:
3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Example\Example_06_show_bmp_picture\show_bmp_picture
Or 3.5inch_Arduino_Mega2560_16BIT_Module_ILI9486_MAR3513_V1.0\1-Demo\Demo_Arduino_Mega2560\Example\Example_06_show_bmp_picture\picture
Note:
Only First blue one is link others are files address in your computer. Such as:
C:\USER\DESKTOP\File\File... etc.
I'm giving you this address just for itself before ones like what I wrote above are changes from computer to computer.
Ouch. LCDWIKI ZIP files are enormous. And the individual file paths are too long for Windows Explorer.
Your TFT should work fine on a Mega2560 with the horrible LCDWIKI libraries.
It should also work with UTFT and TFT_HX8357 libraries too.
The Image2LCD v2.9 utility seems to be able to read a JPG, PNG, ... and convert it to different formats e.g. .BMP
Remember to set all the checkboxes correctly. Create a Horiz Scan 24bit .BMP file. Save on your PC. Display on your PC first. Then copy to your SD card with names like 01.BMP, 02.BMP, ...
Your LCDWIKI example should display your custom image(s).
Personally, I would choose ANY library other than LCDWIKI e.g. TFT_HX8357
Most libraries have examples for displaying 24-bit .BMP files
I strongly advise using a standard format like 24-bit .BMP because you can display on your PC.
PC Graphics, Photo, Paint, ... all understand 24-bit .BMP
Another strategy is to edit, manipulate, resize, ... a JPG on your PC with regular PC programs.
When happy with your pictures, use Image2LCD to convert to a RAW binary file e.g. 16-bit color pixels
Converting to RAW binary file might suit your Arduino program but it makes it non-portable.
David.