I work with MCB1700 evaluation board.
It has (320 x 240) TF LCD Display.
IDE: Keil uvision4 4.03q.
My task is to download picture from PC to MCB1700, display it on LCD
and download on USB-stick (that connects to the board).
I need 320*240*2 = 153600 bytes of memory.
MCB1700 has only 64kB SRAM, and 512kB of on-chip Flash memory.
Obviously, I must store picture in Flash memory.
As I understand, I should bind pointer directly to memory address.
/* Base addresses */
#define LPC_FLASH_BASE (0x00000000UL) //beginning address of on-chip Flash
#define LPC_IMAGE_ADDR (LPC_FLASH_BASE + 0x10000)
#define ImagePtr ((unsigned short *) LPC_IMAGE_ADDR )
//read-write operations
ImagePtr[0] = 0x0124; //First pixel
…
ImagePtr[320*240] = 0xFA37; //Last pixel
unsigned short A = ImagePtr[0];
Is it correct?
I have a doubts because of Target’s options.
Flash memory’s area is defined like Read/Only IROM1.
Does it mean that we can only read data from Flash and must change Memory area in IROM and IRAM fields to perform writing operation? For example in such way: