From 738ace15de626866604ee927dc378c602de01fc8 Mon Sep 17 00:00:00 2001 From: Peng Fan Date: Fri, 31 Jul 2015 10:38:38 +0800 Subject: MLK-11263-1 video: epdc: support display logo on E-Ink screen Support draw image on E-ink screen. 1. The image format should be PGM-P5 raw data format. 2. The image should be named epdc_logo.pgm. 3. If no epdc_logo.pgm found in the first partition(FAT), will choose to draw black border on the screen. 4. Default configuration is to draw image at pos (0,0). If 'splashpos' env is set, will choose the pos from 'splashpos'. 5. The image size should not be bigger than screen total pixel size. 6. Implement board_setup_logo_file in board/freescale/common/epdc_setup.c 7. Introudce function prototype for board_setup_logo_file. Note: i.MX7D EPDC supports advanced mode and standard mode. Since current PXP in uboot for i.MX7D not ready, only support standard mode now. advanced and standard mode needs waveform firmware's support. Signed-off-by: Peng Fan --- drivers/video/mxc_epdc_fb.c | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) (limited to 'drivers/video/mxc_epdc_fb.c') diff --git a/drivers/video/mxc_epdc_fb.c b/drivers/video/mxc_epdc_fb.c index cd18058..f50c509 100644 --- a/drivers/video/mxc_epdc_fb.c +++ b/drivers/video/mxc_epdc_fb.c @@ -350,21 +350,13 @@ static void draw_splash_screen(void) void lcd_enable(void) { - int i; + if (board_setup_logo_file(lcd_base)) { + debug("Load logo failed!\n"); + return; + } epdc_power_on(); - /* Draw black border around framebuffer*/ - memset(lcd_base, 0xFF, panel_info.vl_col * panel_info.vl_row); - memset(lcd_base, 0x0, 24 * panel_info.vl_col); - for (i = 24; i < (panel_info.vl_row - 24); i++) { - memset((u8 *)lcd_base + i * panel_info.vl_col, 0x00, 24); - memset((u8 *)lcd_base + i * panel_info.vl_col - + panel_info.vl_col - 24, 0x00, 24); - } - memset((u8 *)lcd_base + panel_info.vl_col * (panel_info.vl_row - 24), - 0x00, 24 * panel_info.vl_col); - flush_cache((ulong)lcd_base, panel_info.vl_col * panel_info.vl_row); /* Draw data to display */ -- cgit v1.1