Dual Display Based on i.MX6Q via HDMI & VGA(Analog RGB )

Document created by Wigros Sun Employee on Sep 20, 2016
Version 1Show Document
  • View in full screen mode

Two IPUs are supported in i.MX6Q SoC, each IPU supports 1920x1080 resolution, and 4 kinds of interfaces on i.MX6Q PADs can be used to connect display devices: HDMI, Digital RGB24, LVDS1+LVDS2, MIPI DSI.

In the documents, we will discuss how to expand VGA port with digital RGB and realize dual-display via HDMI & VGA, The solution has been validated on Android4.2.2 and Android4.4.2 BSP released by NXP.

1.  Expanding VGA port based on digital RGB24 interface with ADV7125

Schematic is in attachments.

2. Configurations of envionment variables in u-boot

The following settings are for booting via NFS, users can adjust them to boot via Flash on board.

setenv ipaddr
setenv serverip
setenv gateway
setenv ethaddr 00:04:9f:00:ea:d3
setenv bootargs_base 'setenv bootargs console=ttymxc0,115200'
setenv bootargs_android 'setenv bootargs ${bootargs} init=/init androidboot.console=ttymxc0 androidboot.hardware=freescale'
setenv bootargs_nfs 'setenv bootargs ${bootargs} ip=${ipaddr}:${serverip}:${gateway}:${netmask}::eth0 off root=/dev/nfs nfsroot=${serverip}:${nfsroot}'
setenv bootargs_disp 'setenv bootargs ${bootargs} video=mxcfb0:dev=hdmi,1920x1080M@60,if=RGB24,bpp=32 video=mxcfb1:dev=lcd,1920x1080M@60,if=RGB24,bpp=32 video=mxcfb2:off fbmem=32M vmalloc=400M'
setenv bootcmd_net 'run bootargs_base bootargs_android bootargs_nfs bootargs_disp;tftpboot ${loadaddr} uImage;bootm'

3. Configurations in BSP file

(1)IOMUX of DISP0 port (in header file)

    MX6Q_PAD_DI0_PIN15__IPU1_DI0_PIN15,        /* DE */
    MX6Q_PAD_DI0_PIN2__IPU1_DI0_PIN2,        /* HSync */
    MX6Q_PAD_DI0_PIN3__IPU1_DI0_PIN3,        /* VSync */
    MX6Q_PAD_NANDF_D4__GPIO_2_4,        /* ADV7125 Power on / off

(2) Frame buffer

static struct ipuv3_fb_platform_data qcorein_fb_data[] = {
/*    {
    .disp_dev = "ldb",
    .interface_pix_fmt = IPU_PIX_FMT_RGB666,
    .mode_str = "LDB-WXGA",
    .default_bpp = 16,
    .int_clk = false,
    .late_init = false,
    }, */
    .disp_dev = "hdmi",
    .interface_pix_fmt = IPU_PIX_FMT_RGB24,
    .mode_str = "1920x1080M@60",
    .default_bpp = 32,
    .int_clk = false,
    .late_init = false,
    .disp_dev = "lcd",
    .interface_pix_fmt = IPU_PIX_FMT_RGB24,
    .mode_str = "1920x1080",
    .default_bpp = 32,
    .int_clk = false,

(3) Settings about IPUs

/* HDMI -- IPU1_DI0 */
static struct fsl_mxc_hdmi_core_platform_data hdmi_core_data = {
    .ipu_id = 1,
    .disp_id = 1,


/* RGB24 DISP0 LCD(Here is RGB24-->VGA via ADV7125 -- IPU0_DI0 */
static struct fsl_mxc_lcd_platform_data lcdif_data = {
    .ipu_id = 0,
    .disp_id = 0,
    .default_ifmt = IPU_PIX_FMT_RGB24,

(4) Adding LCD data in board_init() funtion

static void __init mx6_qcorein_board_init(void)






(5) Adding mxc_lcd.c driver to linux kernel

When using make menuconfig to configure kernel, don't forget to add LCD driver to kernel.


 Note: If users are using other version of android BSP, she can do porting according to above thinking.


Weidong Sun

NXP TIC team

1 person found this helpful