lpcware

Emwin Fonts in SDRAM + LPC1788

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by anuj.tanksali on Sat Aug 30 08:57:26 MST 2014
Hi,

I have successfully run Emwin on my LPC 1788 board with Emwin fonts. The Emwin Fonts are stored in external NAND flash and on boot up of my system l copy the fonts from NAND flash to SDRAM. I have defined the mapping of fonts in scatter file. In the actual font.c file i have added __attribute to each font array and defined section which i use in my scatter file. I am using keil IDE and extract the font file image using fromelf utility provided by keil to get a bin file. I have defined the load and execution regions in which i have included the sections. i have defined the execution region of SDRAM from 0xA1000000 with 16mb size.

I download the hex file and font file which i extract using fromelf to my board using a PC utility. All is working file and i get to see the fonts on my 7" 800 x 480 pixel display. 

As i download the fonts once in my external NAND i assume that i need not download again and just program only the hex file.
all works well when i compile and download all my files at once i.e. hex + font file. but the second time when i download only the hex file with some changes only in hex not font file i get a hard fault error.

After compiling if i download hex + font file everytime then it works fine.
as the font bin is already present in NAND and i copy from NAND to SDRAM on boot up i feel it should work if the font is already present and i need to download only hex every time but its not working. I am stuck up , dont know what am i doing wrong. has anybody come across such a problem. Please help

Thanks in advance,

Anuj

Outcomes