How to configure LVDS


#1

Hi everyone,

I bought a BPI-M2 board to use with a LVDS display. It is a serious advantage of the Banana Pi-s over the Raspberry Pi big brother is the LVDS interface. Anyone trying to develop anything beyond a hobby project would design using a SBC that has LVDS. Parallel would run you up to 800x480 at best.

I did a quick attempt to reconfigure the ports in MUX3 mode using the FEX file in Ubuntu 16.04. All I got is a blank display with backlight.

I am connecting an Innolux 1280x768 display, all timing data is available to me.

I am using the following as source of schematics to the M2:

https://drive.google.com/folderview?id=0B4PAo2nW2KfnflVqbjJGTFlFTTd1b1o1OUxDNk5ackVDM0RNUjBpZ0FQU19SbDk1MngzZWM&usp=sharing&tid=0B4PAo2nW2Kfndjh6SW9MS2xKSWs

OS is updated/upgraded Ubuntu 16.04 image from: http://www.banana-pi.org/m2-download.html

For configuration reference I use the following: http://linux-sunxi.org/Fex_Guide#.5Bleds_para.5D

I came up with the following to set the ports:

[lcd0_para]
lcd_used = 1
lcd_x = 1280
lcd_y = 768
lcd_dclk_freq = 67
lcd_pwm_not_used = 0
lcd_pwm_ch = 0
lcd_pwm_freq = 22000
lcd_pwm_pol = 0
lcd_max_bright = 240
lcd_min_bright = 64
lcd_if = 3
lcd_hbp = 80
lcd_ht = 1380
lcd_vbp = 20
lcd_vt = 1650
lcd_vspw = 10
lcd_hspw = 50
lcd_hv_if = 0
lcd_hv_smode = 0
lcd_hv_s888_if = 0
lcd_hv_syuv_if = 0
lcd_lvds_ch = 0
lcd_lvds_mode = 0
lcd_lvds_bitwidth = 0
lcd_lvds_io_cross = 0
lcd_cpu_if = 0
lcd_frm = 0
lcd_io_cfg0 = 268435456
lcd_gamma_correction_en = 0
lcd_gamma_tbl_0 = 0x0
lcd_gamma_tbl_1 = 0x10101
lcd_gamma_tbl_255 = 0xffffff
lcd_bl_en_used = 1
lcd_bl_en = port:PH08<1><0><default><1>
lcd_power_used = 1
lcd_power = port:PH12<1><0><default><1>
lcd_pwm_used = 1
lcd_pwm = port:PH13<2><0><default><default>
lcdd0 = port:PD00<3><0><default><default>
lcdd1 = port:PD01<3><0><default><default>
lcdd2 = port:PD02<3><0><default><default>
lcdd3 = port:PD03<3><0><default><default>
lcdd4 = port:PD04<3><0><default><default>
lcdd5 = port:PD05<3><0><default><default>
lcdd6 = port:PD06<3><0><default><default>
lcdd7 = port:PD07<3><0><default><default>
lcdd8 = port:PD08<3><0><default><default>
lcdd9 = port:PD09<3><0><default><default>
lcdd10 = port:PD10<2><0><default><default>
lcdd11 = port:PD11<2><0><default><default>
lcdd12 = port:PD12<2><0><default><default>
lcdd13 = port:PD13<2><0><default><default>
lcdd14 = port:PD14<2><0><default><default>
lcdd15 = port:PD15<2><0><default><default>
lcdd16 = port:PD16<2><0><default><default>
lcdd17 = port:PD17<2><0><default><default>
lcdd18 = port:PD18<2><0><default><default>
lcdd19 = port:PD19<2><0><default><default>
lcdd20 = port:PD20<2><0><default><default>
lcdd21 = port:PD21<2><0><default><default>
lcdd22 = port:PD22<2><0><default><default>
lcdd23 = port:PD23<2><0><default><default>
lcdclk = port:PD24<2><0><default><default>
lcdde = port:PD25<2><0><3><default>
lcdhsync = port:PD26<2><0><3><default>
lcdvsync = port:PD27<2><0><3><default>

One thing to note is the FEX file in the latest distribution of Ubuntu for M2 is really messed up. Most of the peripherals, including the LEDs, appear misplaced. It is if the kernel is using DT not FEX ?!?

Can anyone help me to some tutorial on how to configure the Allwinner SoC?


(Gianluca) #2

Hi, did you find the solution? I would like to use it too.