CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-201显示流程框架CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-202Contents硬件介绍软件框架Soc显示区别CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-203ConceptsCopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-204标准和分辨率分辨率是指显示器上包含的色点数,人们把这些色点叫做像素。分辨率由横轴(行)和纵轴(列)上的像素数表示,例如800x600。包括屏幕大小在内的很多因素都会对分辨率产生影响CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-205接口支持CPU/TTL/RGB(数字并行)VGA/YPBRR/CVBS/S-Video(模拟)HDMI/MIPI/LVDS(数字串行)CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-206接口支持IO引脚的配置定义:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-207HDMI的几个术语CEC简化数字家庭的操作HDCP全称是High-bandwidthDigitalContentProtection,即高带宽数字内容保护。CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-208全志SOC硬件框架图CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-209全志SOC硬件框架图CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2010软件流程UI流程CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2011显示技术ScalerCopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2012显示技术Alpah运算:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2013显示技术调色板:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2014显示技术CSC:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2015显示技术CSC:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2016显示技术CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2017显示技术CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2018显示技术CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2019显示技术CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2020软件工作流程视频播放显示CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2021SurfaceFlinger的简介SurfaceFlinger只是负责mergeSurface的控制,比如说计算出两个Surface重叠的区域,至于Surface需要显示的内容,则通过skia,opengl和pixflinger来计算,流程如下:threadLoopwaitForEventwaitMessagehandleMessagehandleTransactionhandlePageFliphandleRepaintpostFramebuffersignal/signalEventCopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2022屏的驱动流程屏的上电时序:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2023屏的驱动流程屏的断电时序:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2024屏的驱动流程在代码中更改相关的时序:static__s32LCD_open_flow(__u32sel){LCD_OPEN_FUNC(sel,LCD_power_on,50);//openlcdpower,anddelay50msLCD_OPEN_FUNC(sel,LCD_panel_init,50);//openlcdcontroller,anddelay100msLCD_OPEN_FUNC(sel,TCON_open,200);//openlcdpower,thandelay200msLCD_OPEN_FUNC(sel,LCD_bl_open,0);//openlcdbacklight,anddelay0msreturn0;}static__s32LCD_close_flow(__u32sel){LCD_CLOSE_FUNC(sel,LCD_bl_close,0);//closelcdbacklight,anddelay0msLCD_CLOSE_FUNC(sel,LCD_panel_exit,0);//closelcdcontroller,anddelay0msLCD_CLOSE_FUNC(sel,TCON_close,50);//openlcdpower,thandelay200msLCD_CLOSE_FUNC(sel,LCD_power_off,50);//closelcdpower,anddelay500msreturn0;}更改延时流程时注意:1.在对应的回调函数中如果有用到延时操作的要用udelay,mdelay..一些原子性操作的函数,不要使用usleep,schedule_timeout…一些函数做延时。2.LCD_OPEN_FUNC,LCD_CLOSE_FUNC在定义中注册最多是5个回调。CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2025屏的参数调整CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2026屏的驱动流程配置更改sys_config.fexCopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2027屏的驱动流程刷新率的确定:F=DCLK/(VT*HT)以上配置得到的刷新率是:F=9000000/(525*272)=60CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2028屏的DPI,DP的计算DPI的计算:DP的计算:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2029屏的Gamma测试和设置Gamma示意图:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2030屏的Gamma测试和设置Gamma测试准备:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2031屏的Gamma测试和设置Gamma测试步骤:1.计算理论gamma表,使用以下公式:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2032屏的Gamma测试和设置CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2033屏的Gamma测试和设置测试表如下:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2034屏的Gamma测试和设置CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2035屏的Gamma测试和设置Gamma表测试结果如下:CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2036屏的Gamma测试和设置Gamma表的设定:在sys_config.fex中直接将gamma_en设成1,并将对应的值写入gamma表中即可。CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2037SOC的显示性能区别A31的性能:I)图形处理部分:采用PowerVRSGX544MP2,支持3D输出。支持OpenGL2.0/OpenVL1.1/OpenCL1.1/DX9.3标准。内嵌2D加速器,支持BLT,ROP2/3/4,AphaBlending,Rotation,CSC转换II)显示输入部分:支持4K*4K图像处理:ISPYcbcr和ISPRAWRGB,速度为250Mpixel/s支持8个硬件图层和1个硬件鼠标层,2个硬件输出通道支持各种图像格式输入及格式转换及8K*8K的图像输入支持硬件的图像Enhance处理,显示效果更鲜艳。支持硬件的2个*Scaler及数据的回写。支持硬件的De_interlace及3D视频的处理。III)输出特性HDMI1.4且支持HDCP,速度可达3Gb/chanel,最大可支持4096*2160P@30fpsLVDS/RGB/CPU支持1200/1080p@60fps支持4lanesMIPIDSI,1Gb/Lane,分辨率为1200/1080p@60fps支持单通道双显示设备。支持双通道独立显示。IV)视频输入特性:支持MIPICSI输入:4lanes1Gb/lanes.支持12M的静态图像和1080P@60fps视频输入。支持两路并行12bit输入。CopyRight©2011AllWinnerTechnology,AllRightReserved2013-5-2038SOC的显示性能区别A20的性能:I)图形处理部分:采用Mali400mp2,支持3D输出。支持OpenGL2.0/OpenVL1.1标准内嵌2D加速器,支持BLT,ROP2/3/4,AphaBlending,Rotation,CSCII)显示输入部分:支持8个硬件图层和1个硬件鼠标层,2个硬件输出通道支持各种图像格式输入及格式转换及8K*8K的图像输入支持硬件的图像Enhance处理,显示效果更鲜艳支持硬件的2个*Scaler及数据的回写支持硬件的De_interlace及3D视频的处理III)输出特性HDMI1.4且支持HDCPLVDS/RGB/CPU支持1920*1200TV输出CV