1. Kernel change
diff --git a/drivers/video/mxc/ldb.c b/drivers/video/mxc/ldb.c
index 088d36a..b49ef28 100644
--- a/drivers/video/mxc/ldb.c
+++ b/drivers/video/mxc/ldb.c
@@ -123,6 +123,7 @@ struct fb_videomode mxcfb_ldb_modedb[] = {
0,
FB_VMODE_NONINTERLACED,
FB_MODE_IS_DETAILED,},
+#if 0
{
"XGA", 60, 1024, 768, 15385,
220, 40,
@@ -131,6 +132,17 @@ struct fb_videomode mxcfb_ldb_modedb[] = {
0,
FB_VMODE_NONINTERLACED,
FB_MODE_IS_DETAILED,},
+#endif
+ {
+ /* 1366x768 @ 60 Hz 162M pixel clk*/
+ //" WXGA", 60, 1366, 768, 13255, // 75.44MHz
+ "WXGA", 60, 1360, 768, 13255, // 75.44MHz
+ 190, 10, // 194
+ 30, 8, // 38
+ 65, 12,
+ 0,
+ FB_VMODE_NONINTERLACED,
+ FB_MODE_IS_DETAILED },
};
int mxcfb_ldb_modedb_sz = ARRAY_SIZE(mxcfb_ldb_modedb);
@@ -433,7 +445,7 @@ static int ldb_fb_pre_setup(struct fb_info *fbi)
{
int ipu_di = 0;
struct clk *di_clk, *ldb_clk_parent;
- unsigned long ldb_clk_prate = 455000000;
+ unsigned long ldb_clk_prate = 528080000;
fbi->mode = (struct fb_videomode *)fb_match_mode(&fbi->var,
&fbi->modelist);
This change is for 1366x760 screen.
Since IPU IC require the input/output width must be multiple of 8, so set the screen width to 1360, rather than 1366.
528080000 is 7 times of pix clock, 75.44MHz
2. Android change
In init.freescale.rc, change “setprop ro.AUTO_CONFIG_DISPLAY 1” to “setprop ro.AUTO_CONFIG_DISPLAY 0”
This change is for LVDS0.
3. U-boot command line change
console=ttymxc0 init=/init androidboot.console=ttymxc0 video=mxcdi0fb:RGB666,WXGA ldb=di0 di0_primary ip=dhcp gpu_nommu, gpu_memory=64M
Hello,
I am trying to get an LVDS (1280X800) display up on iMX53 over LVDS0 my display is connected, i have done the following changes :
(a)u-boot arguments :
setenv bootargs_base set bootargs console=ttymxc0,115200 video=mxcdi0fb:RGB666,XGA ldb=single,di0,ch0_map=SPWG
(b)in mx53_loco.c :
static struct fb_videomode video_modes[] = {
{
"XGA", 60, 1280, 800, 14065,
40,40,
10,3,
80, 10,
0,
FB_VMODE_NONINTERLACED,
0,}
}
static struct mxc_fb_platform_data fb_data[] = {
{
.interface_pix_fmt = IPU_PIX_FMT_RGB666,
.mode_str = "XGA",
.mode = video_modes,
.num_modes = ARRAY_SIZE(video_modes),
}
}
(c)ldb.c
struct fb_videomode mxcfb_ldb_modedb[] = {
{
"XGA", 60, 1280, 800, 14065,
40,40,
10,3,
80, 10,
0,
FB_VMODE_NONINTERLACED,
FB_MODE_IS_DETAILED,},
};
(d)in init.freescale.rc
ro.AUTO_CONFIG_DISPLAY 0
but still i am unbale to see any LVDS signals neither data nor clock over the LVDS connector.
Kindly suggest me if anything else has to be taken care inorder to get my LVDS working.
Thanks
Soujanya
Hi,
Soujanya
Your mxcfb_ldb_modedb is correct.
Can you check your datasheet for LVDS panel? I think in your case its 24 bit panel.
You sould video=mxcdi0fb:RGB24 in u-boot argument.
You can refer iMX6QD_How_to_add_24bit_LVDS_support_in_Android.pptx. To add support for 24 bit LVDS panel.
Thanks,
Saurabh
Hi Saurabh,
Thanks a lot for confirming that mxcfb_ldb_modedb is correct.
But the LVDS display i am using has only 3differential lines ==>RGB666, so accordingly i am using the following u-boot arguemnts :
setenv bootargs_base set bootargs console=ttymxc0,115200 video=mxcdi0fb:RGB666,XGA ldb=single,di0,ch0_map=SPWG
Thanks
Soujanya
I tried with following value , but it gives me garbage data on display (monitor's native resolution is 1366x768)
/* VGA 1360x768 75.4M pixel clk output */
"VGA-WXGA", 60, 1360, 768, 13262, // 75.44MHz
208, 72,
17, 3,
136, 10,
FB_SYNC_HOR_HIGH_ACT | FB_SYNC_VERT_HIGH_ACT,
FB_VMODE_NONINTERLACED,
FB_MODE_IS_DETAILED,
I want to do same for VGA output. i know ,i have to change tve.c file . but what should be the value for 1366 x768 @60 resolution in VGA mode. i mean values for fb_videomode structure. and clock
Shaojun Wang said:
For your LCD, the frequency is 10^12/25000 = 40MHz.
sanu said:Hi
How you got the value 75.44MHz?
Could you share it.I am using a LCD having the following value .
{
"TIANMA",60,800,600,25000,
186,40,
25,1,
30,2,
0,
FB_VMODE_NONINTERLACED,
0}
I want to do same for VGA output. i know ,i have to change tve.c file . but what should be the value for 1366 x768 @60 resolution in VGA mode. i mean values for fb_videomode structure. and clock
For your LCD, the frequency is 10^12/25000 = 40MHz.
sanu said:
Hi
How you got the value 75.44MHz?
Could you share it.I am using a LCD having the following value .
{
"TIANMA",60,800,600,25000,
186,40,
25,1,
30,2,
0,
FB_VMODE_NONINTERLACED,
0}
Hi
How you got the value 75.44MHz?
Could you share it.
I am using a LCD having the following value .
{
"TIANMA",60,800,600,25000,
186,40,
25,1,
30,2,
0,
FB_VMODE_NONINTERLACED,
0
}
To enable 1366x768 on LVDS1, only apply 1. Kernel change the u-boot command line is:
console=ttymxc0 init=/init androidboot.console=ttymxc0 video=mxcdi1fb:RGB666,WXGA ldb=di1 di1_primary ip=dhcp gpu_nommu, gpu_memory=64M
To enable 1366x768 on LVDS0, need to apply the three steps.
Yi Li said:
Is this only apply to a new LVDS 1366x768 panel or the same MCIMX-LVDS1 panel?
Is this only apply to a new LVDS 1366x768 panel or the same MCIMX-LVDS1 panel?