cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F103ze Eval Board

shrinath
Associate II
Posted on September 06, 2011 at 10:03

I need to use Ext SRAM in my application.In order to understand how to initialize and use it for read/write, I went through the Data sheet as well created a project from the sample code provided for SRAM under folder called FSMC under Keil/arm/example/ST/STM32F10xFWLib/Example/FSMC

However this program does not run though no compilation error.

In debug mode on tracing, when it is inside FSMC_SRAM_WriteBuffer any write to Ext SRAM displays no permission to write in the command window (similar if I try read to verify data written, shows no permission to read message).Went through the code it appears to have all initialization required for the control bits and timing register.Can some one let me know what changes to be done in which file?

Thanks,

shrinath

regards
4 REPLIES 4
Andrew Neil
Evangelist
Posted on September 06, 2011 at 10:52

''any write to Ext SRAM displays no permission to write in the command window (similar if I try read to verify data written, shows no permission to read message)''

 

This sounds like you have not correctly configured your Keil Project settings to tell the debugger:

  1. That memory does exist in this address range, and
  2. That reading & writing are allowed

http://www.keil.com/support/man/docs/uv4/uv4_cm_map.htm

http://www.keil.com/support/man/docs/gsac/

shrinath
Associate II
Posted on September 06, 2011 at 15:50

Thanks for suggestion, it appears to have resolved a part of issue, though the write function is not writing data(read from Txbuffer) at address mentioned(Ext SRAM) in the function.

shrinath
shrinath
Associate II
Posted on September 06, 2011 at 16:18

Well, I configured the Target with the following inputs:

Read only memory areas:

IROM1 : x08000000  size:0x80000

Read/write memory areas:

RAM1: 0x68000000 size 0x10000

IRAM1:0x20000000   size:10000

now it displays no permission to write in the place where the write operation is happening.

in the example it needs to write at 0x68008000.

thanks,

shrinath

shrinath
Associate II
Posted on September 07, 2011 at 15:57

Well, modified the Target option configuration :

removed internal RAM region changed it to Ext SRAM it works now, so now I have two Ext SRAM region.RAM1 and RAM2.

Thanx