How to configure for 5" LCD

Hi all,

I have this 5" LCD from Newhaven and I am trying to configure the LCD drivers to use it with a ChipworkX board. I tried the CP7 configuration and I get some sort of display but the boot text is off the left side of the display. When I tried to draw on the display, nothing happens.

http://www.newhavendisplay.com/capacitive-touch-tft-nhd50800480tfatxictp-p-5018.html

I’ll offer a free Gadgeteer compatible PCB for this display (I will test with the G120HDR) as a thank you when I have the working boards made if someone can give me the configuration to use or explain how the values in LCDconfig relate to the LCD timing.

Right now I have a custom board with a 40 pin FPC connector on it and plan to add the 10 way Gadgeteer connectors to the next update this month. I’ll happily send you a completed board when I get the first batch of prototypes back.

Thanks
Dave…

Can you show your configuration code, please?

Sure


                lcdConfig.Width = 800;
                lcdConfig.Height = 480;

                lcdConfig.PriorityEnable = false;

                lcdConfig.OutputEnableIsFixed = false;
                lcdConfig.OutputEnablePolarity = true;

                lcdConfig.HorizontalSyncPolarity = true;
                lcdConfig.VerticalSyncPolarity = true;
                lcdConfig.PixelPolarity = false;

                lcdConfig.HorizontalSyncPulseWidth = 1;
                lcdConfig.HorizontalBackPorch = 92;
                lcdConfig.HorizontalFrontPorch = 16;
                lcdConfig.VerticalSyncPulseWidth = 1;
                lcdConfig.VerticalBackPorch = 23;
                lcdConfig.VerticalFrontPorch = 7;

                lcdConfig.PixelClockDivider = 4;

With this I can see the boot text but when I try to draw a bitmap I get lines on the display.

I adjusted the HorizontalBackPorch from the CP7 settings to get the text to move to the right and appear complete on the display.

Timing is still not 100% of course.

@ Dave McLaughlin - I remember Wouter had some issues configuring custom display, but he managed to make it work. See if this helps:

http://www.tinyclr.com/codeshare/entry/555

http://www.tinyclr.com/forum/topic?id=8639
http://www.tinyclr.com/forum/topic?id=8550

Thanks guys. I am still going through the documentation and the datasheet for the LCD to try and figure out what each value is in relation to the timing diagram.

OK. I seem to have something working now except I now get an out of memory exception with Glide when trying to create the bitmap for the window :frowning:

This seems a bit strange though. The ChipworkX has 64MB of RAM and a 800 x 480 window at 16 it would only be 6MB or am I missing something here?

I may have to wait for the G400 to be able to us this display. Pity as it looks great (even if I can only show half the window on it :slight_smile:

Hi Andre,

I will check it out tomorrow. Long day so far and time to get some sleep.

I have switched back to the 4.3" LCD and it created the 800 x 480 bitmap but I noticed that when glide starts it creates a bitmap of the screen size to display the words LOADING. I may edit Glide tomorrow to remove this and I think my code should work. I only every create 1 screen at a time so this idea should work.

By the way, the bmp was being created during GlideLoader creating the window.

I’ll report back if it works.

PS… The 5" LCD looks great. Next step is to get the capactive drivers working and hooked into Glide. If I can do that I may switch to the 5" LCD until I can get the 4.3" touch working. :slight_smile: