cancel
Showing results for 
Search instead for 
Did you mean: 

Code for setting configuration register

jwester9
Associate II
Posted on May 18, 2007 at 09:25

Code for setting configuration register

7 REPLIES 7
jwester9
Associate II
Posted on May 17, 2011 at 09:42

Hi

Can anyone supply me with code for setting Configuration register for changning the boot to bank1, so I can use it instead of the CAPS

Is it the CSX bit ?

mark9
Associate II
Posted on May 17, 2011 at 09:42

No one responded to my earlier post on this, so I assume it is absolutely impossible to set the CSX bit without using JTAG.

jwester9
Associate II
Posted on May 17, 2011 at 09:42

I read more about it and now I understand it can only bee done via JTAG, but how. With JTAG it depends on the IDE system, and maybe it can bee done

by setting registers in the init sequence

I using iSystem and winIDEA, anyone know how to setup the JTAG ??

mark9
Associate II
Posted on May 17, 2011 at 09:42

The fastest way of doing it is using ST Micro's CAPS program, and a Raisonnance RLink jtag adapter.

Otherwise, you will need to study the STR91x Flash Programming manual, which has the details of JTAG bit banging, but that requires knowledge of the jtag protocol (I gave up after a while).

nanuradha
Associate II
Posted on May 17, 2011 at 09:42

Hai,

you can change the csx bit in 91x_CFG.s which will be available in strtup code folder for ST.We are using keil ide.You can add 91x_CFG.s to startupcode and select the csx bit and download the program using JTAG.

k_arthur
Associate II
Posted on May 17, 2011 at 09:42

I will give you some tips.

First of all find in your project the (output) map file like the example is attached. In attached file you will find:

Load Region LR_IROM1 - code

Execution Region RW_IRAM1 - ram

Load Region LR$$.ARM.__AT_0x520000 - configuration this means that after

linking we have code that intended for addresses 0x520000 - 0x520007

Now the programer knows that it must write to flash also this addresses.

k_arthur
Associate II
Posted on May 17, 2011 at 09:42

I use the attached file. But if this file not compatible for your system

you must create code area yourself (see the attached as example change it

to your system if needed). When you receive in your map file the code area

that i explaned before - one step is done. Now may be the programer that

you use can not write that area(no algorithm). Check it before you start.

Than may be it easier to use the caps. Or find the programer that can

program any hex file that support algorithms for different area writing.

Good luck!!!