MCIMX6Q use DISP0 Expansion Connector as the 1280x800 WXGA LCD port ,how to modfying the relative files about kernel_imx ?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MCIMX6Q use DISP0 Expansion Connector as the 1280x800 WXGA LCD port ,how to modfying the relative files about kernel_imx ?

2,637 Views
pengxingwei
Contributor III

Dear all,

    My development board is equipped with Android system, LCD:1280X800 WXGA  262K color (RGB 6-bit data driver)   ,now I want to use the DISP0 Expansion  Connector of MCIMX6Q as the lcd port .The kernel_imx is linux -3.13.0-32 ,I don't kown the location about the file that I need to modfying so that to adapt to my LCD screen.Thanks !

Labels (2)
35 Replies

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

In device tree file, you should modify the "kernel_imx\arch\arm\boot\dts\imx6qdl-sabresd.dtsi" to followed:

mxcfb1: fb@0 {

  compatible = "fsl,mxc_sdc_fb";

  disp_dev = "lcd";

  interface_pix_fmt = "RGB666";

  mode_str ="XXXX-WXGA";

  default_bpp = <32>;

  int_clk = <0>;

  late_init = <0>;

  status = "okey";

};

lcd@0 {

  compatible = "fsl,lcd";

  ipu_id = <0>;

  disp_id = <0>;

  default_ifmt = "RGB666";

  pinctrl-names = "default";

  pinctrl-0 = <&pinctrl_ipu1_1>;

  status = "okay";

};

And in file "kernel_imx\arch\arm\boot\dts\imx6qdl.dtsi", you need check the pin setting of ipu1, is it same as your hardware?

ipu1 {

  pinctrl_ipu1_1: ipu1grp-1 {

   fsl,pins = <

... ...

   >;

  };

And in kernel driver, kernel_imx\drivers\video\mxc\mxc_lcdif.c, you need added your panel timing parameters:

static struct fb_videomode lcdif_modedb[] = {

{

/* 1280x800 @ 60 Hz , pixel clk @ ??MHz */

"XXXX-WXGA", 60, 1280, 800, x, x, x, x, x, x, x,

FB_SYNC_CLK_LAT_FALL,

FB_VMODE_NONINTERLACED,

0,},

Then from kernel boot command line:

video=mxcfb0:dev=lcd,XXXX-WXGA,if=RGB666,bpp=32

0 Kudos

1,318 Views
pengxingwei
Contributor III

Dear Qiang Li,

     Besides,at the file of  kernel_imx\arch\arm\mach-mx6\board-mx6q_sabresd.c, static struct ipuv3_fb_platform_data sabresd_fb_data and static struct fsl_mxc_lcd_platform_data lcdif_data , whether also need to modfying? and the system I use on the board(MCIMX6Q SDB) is the Android system .I'm looking forward to your quick reply,thanks !

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

Yes, you should change it.

"The kernel_imx is linux -3.13.0-32", it is not Freescale released BSP.

0 Kudos

1,318 Views
pengxingwei
Contributor III

I want to kown the different of the kernel_imx after I use the android_kk4.4.3_2.0.0 BSP and  android_jb4.3_1.1.0BSP by the step of git checkout, although I find some different .And acoording to two different BSP, How to modify the file respectively for different BSP to adapt to my LCD? now I am confused accoding to some bbs,so I need you to give me light!Thank you very much!

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

For android_kk4.4.3_2.0.0 BSP, it is device tree based kernel, the modifications had been given in above discussion.

For android_jb4.3_1.1.0 BSP, it is not device tree based kernel, so all device tree file modifications are in board file, such as board-mx6q_sabresd.c and board-mx6q_sabresd.h.

And the kernel driver code modification is same in mxc_lcdif.c.

0 Kudos

1,318 Views
pengxingwei
Contributor III

sorry,can you tell me which files I need to modyfing to adapt to my screen when I use the Android_jb4.3_1.1.0-ga_core_source BSP.Thank you very much!

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

kernel_imx/arch/arm/mach-mx6/board-mx6q_sabresd.c

kernel_imx/arch/arm/mach-mx6/board-mx6q_sabresd.h

kernel_imx/arch/arm/mach-mx6/board-mx6dl_sabresd.h

kernel_imx/drivers/video/mxc/mxc_lcdif.c

0 Kudos

1,318 Views
pengxingwei
Contributor III

I use the Android_jb4.3_1.1.0-ga_source BSP , for the kernel_imx,I modfied:

1.\ myandroid\kernel_imx\drivers\video\mxc\mxc_lcdif.c

static struct fb_videomode lcdif_modedb[]= {

{

/* 1280x800 @ 60 Hz , pixel clk @ 68.93MHz */

"LCD-WXGA", 60, 1280, 800, 14507, 60, 60, 6, 8, 48, 2,

FB_SYNC_CLK_LAT_FALL,

FB_VMODE_NONINTERLACED,

0,},

2.\myandroid\kernel_imx\arch\arm\mach-mx6\board-mx6q_sabresd.c:

1) static struct ipuv3_fb_platform_data sabresd_fb_data[] = {
        { /*fb0*/
        .disp_dev = "lcd",
        .interface_pix_fmt = IPU_PIX_FMT_RGB666,
        .mode_str = "LCD-WXGA",
        .default_bpp = 32,
        .int_clk = false,
        .late_init = false,
        },
...
}

2)static struct fsl_mxc_lcd_platform_data lcdif_data[]
static struct fsl_mxc_lcd_platform_data lcdif_data = {
        .ipu_id = 0,
        .disp_id = 0,
        .default_ifmt = IPU_PIX_FMT_RGB666,
};

3.kernel boot command line:
video=mxcfb0:dev=lcd,LCD-WXGA,if=RGB666,bpp=32

After modfying ,I compiled the kernel_imx again,download to the board,but the screen was't lingt,the start log:

4.3启动log.doc_免费高速下载|百度云 网盘-分享无限制

I also don't kown whether the LCD driver started.

the data of the LCD screen:P101E1A0F-V3KP_20130805丰艺组装屏.pdf_免费高速下载|百度云 网盘-分享无限制

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

From your log, the LCD driver had been loaded.

Please disacble kernel config "CONFIG_MX6_CLK_FOR_BOOTUI_TRANS=y", that is for LVDS panel only.

0 Kudos

1,318 Views
pengxingwei
Contributor III

3.jpg

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

Did you  remove "CONFIG_MX6_CLK_FOR_BOOTUI_TRANS=y" from kernel config file? It is in kernel_imx\arch\arm\configs\imx6_android_defconfig.

After removed that, please capture the boot log again.

From your old log, there is error "IPU Warning - IPU_INT_STAT_10 = 0x00100000".

If there is no error again, but your display still has nothing, you need measure the LCD signal and compare with your LCD datasheet to check if it is correct or not.

0 Kudos

1,318 Views
pengxingwei
Contributor III

And what files that I need  to replace to download when I compile myself images.only the android_jb4.3_1.1.0-ga_tool\Mfgtools-Rel-13.01.00_ER_MX6Q_UPDATER\Profiles\MX6Q Linux Update\OS Firmware\files\android\boot.img、system.img、recovery.img.u-boot-6q.bin ?

The rest of the file does not need to be replaced when I download by the MFGTOOLS?

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

Since you are debug on Freescale board and only modified the kernel, you just need replace boot.img.

0 Kudos

1,318 Views
pengxingwei
Contributor III

I removed "CONFIG_MX6_CLK_FOR_BOOTUI_TRANS=y" from kernel config file.the new log:log.txt_免费高速下载|百度云 网盘-分享无限制

And can you tell me how to find that the LCD driver was loaded.

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

Please change "fbmem=10M" to "fbmem=20M", and delete "fb0base=0x27b00000" in your kernel boot command.

Th fbmem should be bigger than 3 x Frame buffer size, your frame buffer size is 1280*800*(32/8)= 0x3E8000, so 3*0x3E8000 = 0xBB8000, it is bigger than 10MB.

0 Kudos

1,318 Views
pengxingwei
Contributor III

I do it according your suggestion,but the effect  has not changed.

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

Please attach log.

0 Kudos

1,318 Views
pengxingwei
Contributor III

new_log.txt_免费高速下载|百度云 网盘-分享无限制​ That is the new log after changing "fbmem=10M" to "fbmem=20M", and deleteing "fb0base=0x27b00000" in your kernel boot command.

0 Kudos

1,318 Views
qiang_li-mpu_se
NXP Employee
NXP Employee

There is no error in software size now, if your LCD has no display, you need measure the hardware signal, such as LCD power, pixel clock, HSYNC, VSYNC, Date Enable, and compare with the LCD datasheet.

0 Kudos

1,318 Views
pengxingwei
Contributor III

Hello,I find there are two lcd (CLAA-WVGA and SEIKO-WVGA)at the mxc_lcdif.c,and there exists two LCD init drivers(mxcfb_claa_wvga.c and mxcfb_seiko_wvga.c) at the kernel_imx/drivers/video/mxc,therefore for my lcd:LCD-WXGA,Whether we should also increase the corresponding initialization driver so that the driver can work?

0 Kudos