LCP1788 LCD frame buffer in internal RAM

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LCP1788 LCD frame buffer in internal RAM

792 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bourgeois on Wed Dec 28 09:28:54 MST 2011
Hello,

Is it possible to use the onchip RAM for an LCD frame buffer? I ask because, I have some sample code that runs only when the frame buffer is located on external RAM.

I have something like that:

int32_t framebuf = (int32_t)(0xA0000000); // external RAM

but when I change to:

int32_t framebuf = (int32_t)(0x10000000); // internal RAM

it doesn't work anymore.

The address is set with:
LPC_LCD->UPBASE = (uint32_t)framebuf;

(The address is reserved for the frame buffer and the linker don't put variables in that region.)

For information, I have the EA Board for the LPC1788.
Labels (1)
0 Kudos
6 Replies

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by marsal87 on Tue Oct 02 01:36:15 MST 2012
Hello bourgeois,

I am trying to get multiply buffering to work, but without success.
Could you please send me your LCDConf.c and GUIConf.c?
I thank you ahead.

Best regards,
marsal87
0 Kudos

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by wellsk on Thu Jan 12 09:40:36 MST 2012
Hi Bourgeois,

You cannot use the internal 64K RAM bank for the LCD frame buffer. The internal AHB bus isn't attached to that memory or FLASH. For the internal IRAM, it can only be used for code/data space for the CPU and the general purpose DMA. You can get an idea of the bus matrix connections in the "CPU and busses" block diagram in the lpc177x user manual.

You can use peripheral RAM for the LCD frame buffer or external memory on the External Memory Controller.

For a 320x240 pixel display at 16bits/pixel(bpp) (2 bytes/pixel), this would require about 150K. Even at 4bpp, it would still require more memory than the peripheral RAM provides.
0 Kudos

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bourgeois on Thu Jan 12 08:04:45 MST 2012
Has someone got an idea regarding this issue?
0 Kudos

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bourgeois on Thu Jan 12 08:04:17 MST 2012
deleted
0 Kudos

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bourgeois on Thu Dec 29 01:49:51 MST 2011
Hi

Thanks for the reply. I know about the size. The resolution is 320*240 with 4bpp --> size 0x9600 (37kB).

The LPC1788 has two internal RAM region. I tried to put it in the second region with:

int32_t framebuf = (int32_t)(0x20000000); // internal RAM region 2

and it worked. But since the size of this region is too small (0x8000) for my buffer I had to change to 2bpp. But that is not an option for my purpose.

Any idea what I can do, to put it in the internal RAM region 1?
0 Kudos

677 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by pcproa on Wed Dec 28 17:05:34 MST 2011
Most LCD's are too large (Pixel Length * Pixel Width * Colour Depth in bits = Bits needed for Frame Buffer) which exceeds the amount of space available to an LCD for an internal frame buffer. What is the resolution of your LCD and how many bits is it?
The LPC1788 has 96kBytes (786k Bits) of internal SRAM, and I believe a very large chunk of that is available to the AHB Peripherals.
0 Kudos