PiMan1337
Posts: 6
Joined: Tue Jan 16, 2018 9:43 am

Can’t get DPI working on the CM3

Tue Feb 06, 2018 8:55 am

Hi everybody! So I recently started a project around the CM3 and the official IOBoard, the goal is to drive a 24bit DPI LCD screen through the J5 header!

PROBLEM
The problem is that I’m getting "White Screen", which is supposed to be caused by a faulty connection but I am pretty sure I’ve hooked it up correctly. And if it is hooked up incorrectly, could you change the pins using the dt-blob?

Also as a side note I’m not sure if I hooked up pin 31(DISP) correctly, I’ve hooked it up to GND and 3.3V (VCC) through a 1K and 10K resistor but there is no change in behavior. I know it’s not the main problem but I couldn’t find anything in the datasheet about it.

WHAT IVE TRIED
I designed an adapter board to connect the 40pin FFC socket to the J5 header of the IO Board, I’m pretty sure it’s correct (This is not final, just for testing) Se images below!

I’ve also edited the config.txt (Se code below) to use the Alt2 function of the "DPI" pins and disable the I2C interface on J5.

Since the CM3 modules only come with a 4GB of EMMC storage (excluding the NEC-Edition) I had to install the "Lite" version of raspbian. I have however installed the RPD and xServer just to be on the safe side. I’ve tried both with the desktop environment installed and without and i get the same problem. The guide used: viewtopic.php?t=133691

The screen I’m using is a 5" TFT LCD.
Datasheet: http://www.farnell.com/datasheets/21515 ... 1516606088

Thanks in advanced for any help!

UPDATE
As a quick update of what I’ve tried.
Custom timings: I’ve read through the datasheet a few more times and customized the "hdmi_timings" a bit more, it seems to do better (no strange lines at startup) but I still get white screen. I think it has to do with the DISP pin and the screen not turning on like it should.
Not really sure though.
If someone could shed some light on this it would be much appreciated!

Code: Select all

hdmi_timings=1056 0 256 50 256 525 0 45 50 45 0 0 0 60 0 333000000

hdmi_timings=800 0 256 50 256 480 0 45 50 45 0 0 0 60 0 333000000
Image
Image



Code: Select all

kernel=uboot.bin
dtparam=act_led_trigger=heartbeat



#Interface configuartion

dtparam=uart0=off
enable_uart=0
dtparam=i2c_arm=off
dtparam=i2s=off
dtparam=spi=off

#Default is 700MHz
#arm_freq=800


# Screen Configuration

framebuffer_width=800
framebuffer_height=480

dtoverlay=dpi24

overscan_left=0
overscan_right=0
overscan_top=0
overscan_bottom=0

enable_dpi_lcd=1
display_default_lcd=1

dpi_group=2
dpi_mode=87
dpi_output_format=0x6f005
hdmi_timings=800 0 40 48 88 480 0 13 3 32 0 0 0 60 0 32000000 6

aBUGSworstnightmare
Posts: 948
Joined: Tue Jun 30, 2015 1:35 pm

Re: Can’t get DPI working on the CM3

Wed Feb 07, 2018 3:49 pm

most likely your Timing is incorrect.

maybe you want to try this (Change in config.txt;

Code: Select all

dtoverlay=dpi24

# Disable spi and i2c
dtparam=spi=off
dtparam=i2c_arm=off
 
# Set screen size and any overscan required
overscan_left=0
overscan_right=0
overscan_top=0
overscan_bottom=0
framebuffer_width=800
framebuffer_height=480
 
# enable the DPI display
enable_dpi_lcd=1
display_default_lcd=1
 
dpi_group=2
dpi_mode=87
 
# set up the hsync/vsync/clock polarity and format
dpi_output_format=454661
 
# set up the size to 800x480
hdmi_timings=800 0 40 48 88 480 0 13 3 32 0 0 0 60 0 32000000 6
This is the timing for Adafruit 5in TFT. Both modules look pretty Close from their spec, so simply give it a try.
Btw: have you confirmed your Adapter PCB is working at all? I.e. hooking it up to a Rpi3 with a bunch of jumper wires ...

aBUGSworstnightmare
Posts: 948
Joined: Tue Jun 30, 2015 1:35 pm

Re: Can’t get DPI working on the CM3

Wed Feb 07, 2018 3:50 pm

Forgot to mention: simply connect DISP to VCC (via 10k pull-up or directly) if you don't want to control it.

PiMan1337
Posts: 6
Joined: Tue Jan 16, 2018 9:43 am

Re: Can’t get DPI working on the CM3

Wed Feb 07, 2018 4:22 pm

aBUGSworstnightmare wrote:
Wed Feb 07, 2018 3:49 pm
most likely your Timing is incorrect.

maybe you want to try this (Change in config.txt;

Code: Select all

dtoverlay=dpi24

# Disable spi and i2c
dtparam=spi=off
dtparam=i2c_arm=off
 
# Set screen size and any overscan required
overscan_left=0
overscan_right=0
overscan_top=0
overscan_bottom=0
framebuffer_width=800
framebuffer_height=480
 
# enable the DPI display
enable_dpi_lcd=1
display_default_lcd=1
 
dpi_group=2
dpi_mode=87
 
# set up the hsync/vsync/clock polarity and format
dpi_output_format=454661
 
# set up the size to 800x480
hdmi_timings=800 0 40 48 88 480 0 13 3 32 0 0 0 60 0 32000000 6
This is the timing for Adafruit 5in TFT. Both modules look pretty Close from their spec, so simply give it a try.
Btw: have you confirmed your Adapter PCB is working at all? I.e. hooking it up to a Rpi3 with a bunch of jumper wires ...
I’ve updated the timing to better suit the screen I’m using, it didn’t change anything, I still think its wrong but I’m not sure, the screen is a bit purple/blue instead of white now. The timing table was a bit vague.
I have not tried to connect the screen adapter to a RPI3 board.

aBUGSworstnightmare
Posts: 948
Joined: Tue Jun 30, 2015 1:35 pm

Re: Can’t get DPI working on the CM3

Thu Feb 08, 2018 6:53 am

Code: Select all

sudo raspi-gpio get
post the result here (want to check if your GPIO is configured correctly)

PiMan1337
Posts: 6
Joined: Tue Jan 16, 2018 9:43 am

Re: Can’t get DPI working on the CM3

Fri Feb 09, 2018 7:55 am

aBUGSworstnightmare wrote:
Thu Feb 08, 2018 6:53 am

Code: Select all

sudo raspi-gpio get
post the result here (want to check if your GPIO is configured correctly)
These are the results!

Code: Select all

BANK0 (GPIO 0 to 27):
GPIO 0: level=1 fsel=6 alt=2 func=PCLK
GPIO 1: level=0 fsel=6 alt=2 func=DE
GPIO 2: level=0 fsel=6 alt=2 func=LCD_VSYNC
GPIO 3: level=0 fsel=6 alt=2 func=LCD_HSYNC
GPIO 4: level=0 fsel=6 alt=2 func=DPI_D0
GPIO 5: level=0 fsel=6 alt=2 func=DPI_D1
GPIO 6: level=0 fsel=6 alt=2 func=DPI_D2
GPIO 7: level=0 fsel=6 alt=2 func=DPI_D3
GPIO 8: level=0 fsel=6 alt=2 func=DPI_D4
GPIO 9: level=0 fsel=6 alt=2 func=DPI_D5
GPIO 10: level=0 fsel=6 alt=2 func=DPI_D6
GPIO 11: level=0 fsel=6 alt=2 func=DPI_D7
GPIO 12: level=0 fsel=6 alt=2 func=DPI_D8
GPIO 13: level=0 fsel=6 alt=2 func=DPI_D9
GPIO 14: level=0 fsel=6 alt=2 func=DPI_D10
GPIO 15: level=0 fsel=6 alt=2 func=DPI_D11
GPIO 16: level=0 fsel=6 alt=2 func=DPI_D12
GPIO 17: level=0 fsel=6 alt=2 func=DPI_D13
GPIO 18: level=0 fsel=6 alt=2 func=DPI_D14
GPIO 19: level=0 fsel=6 alt=2 func=DPI_D15
GPIO 20: level=0 fsel=6 alt=2 func=DPI_D16
GPIO 21: level=0 fsel=6 alt=2 func=DPI_D17
GPIO 22: level=0 fsel=6 alt=2 func=DPI_D18
GPIO 23: level=0 fsel=6 alt=2 func=DPI_D19
GPIO 24: level=0 fsel=6 alt=2 func=DPI_D20
GPIO 25: level=0 fsel=6 alt=2 func=DPI_D21
GPIO 26: level=0 fsel=6 alt=2 func=DPI_D22
GPIO 27: level=0 fsel=6 alt=2 func=DPI_D23
BANK1 (GPIO 28 to 45):
GPIO 28: level=0 fsel=0 func=INPUT
GPIO 29: level=0 fsel=0 func=INPUT
GPIO 30: level=0 fsel=0 func=INPUT
GPIO 31: level=0 fsel=0 func=INPUT
GPIO 32: level=0 fsel=0 func=INPUT
GPIO 33: level=0 fsel=0 func=INPUT
GPIO 34: level=1 fsel=0 func=INPUT
GPIO 35: level=1 fsel=0 func=INPUT
GPIO 36: level=1 fsel=0 func=INPUT
GPIO 37: level=0 fsel=0 func=INPUT
GPIO 38: level=0 fsel=0 func=INPUT
GPIO 39: level=0 fsel=0 func=INPUT
GPIO 40: level=0 fsel=0 func=INPUT
GPIO 41: level=0 fsel=0 func=INPUT
GPIO 42: level=0 fsel=0 func=INPUT
GPIO 43: level=0 fsel=0 func=INPUT
GPIO 44: level=0 fsel=0 func=INPUT
GPIO 45: level=0 fsel=0 func=INPUT
BANK2 (GPIO 46 to 53):
GPIO 46: level=1 fsel=0 func=INPUT
GPIO 47: level=1 fsel=0 func=INPUT
GPIO 48: level=0 fsel=4 alt=0 func=SD0_CLK
GPIO 49: level=1 fsel=4 alt=0 func=SD0_CMD
GPIO 50: level=1 fsel=4 alt=0 func=SD0_DAT0
GPIO 51: level=1 fsel=4 alt=0 func=SD0_DAT1
GPIO 52: level=1 fsel=4 alt=0 func=SD0_DAT2
GPIO 53: level=1 fsel=4 alt=0 func=SD0_DAT3

aBUGSworstnightmare
Posts: 948
Joined: Tue Jun 30, 2015 1:35 pm

Re: Can’t get DPI working on the CM3

Fri Feb 09, 2018 10:33 am

GPIO are configured for DPI --> next step would be to check the I/O board. Conncet CLK/DE/VSYNC/HSYNC and one Color only and see what happens. If the Display stays White your 'magic number' and/or HMDI Settings are wrong

PiMan1337
Posts: 6
Joined: Tue Jan 16, 2018 9:43 am

Re: Can’t get DPI working on the CM3

Fri Feb 09, 2018 11:34 am

aBUGSworstnightmare wrote:
Fri Feb 09, 2018 10:33 am
GPIO are configured for DPI --> next step would be to check the I/O board. Conncet CLK/DE/VSYNC/HSYNC and one Color only and see what happens. If the Display stays White your 'magic number' and/or HMDI Settings are wrong
So I hooked up CLK/DE/VSYNC/HSYNC and D0-D7 (Blue) and I still shows white screen. Could you please help me out with the timing, I thought it was correct. When comparing the timing table from my screen and the timing table used in the Adafruit example it seems viable.

PiMan1337
Posts: 6
Joined: Tue Jan 16, 2018 9:43 am

Re: Can’t get DPI working on the CM3

Mon Mar 12, 2018 10:33 am

PiMan1337 wrote:
Fri Feb 09, 2018 11:34 am
aBUGSworstnightmare wrote:
Fri Feb 09, 2018 10:33 am
GPIO are configured for DPI --> next step would be to check the I/O board. Conncet CLK/DE/VSYNC/HSYNC and one Color only and see what happens. If the Display stays White your 'magic number' and/or HMDI Settings are wrong
So I hooked up CLK/DE/VSYNC/HSYNC and D0-D7 (Blue) and I still shows white screen with a tint of blue/purple (just like earlier). Could you please help me out with the timing, I thought it was correct. When comparing the timing table from my screen and the timing table used in the Adafruit example it seems viable.


Last bumped by PiMan1337 on Mon Mar 12, 2018 10:33 am.

Return to “Interfacing (DSI, CSI, I2C, etc.)”

Who is online

Users browsing this forum: No registered users and 11 guests