Keil™, An ARM® Company

Technical Support

MCBSTR9: BOOTING FROM FLASH BANK1


Information in this article applies to:

  • MCBSTR9 Evaluation Board

QUESTION

I am using a MCBSTR9 Board and I want my application to boot from Flash Bank1. What must I change in my project to achieve this?

ANSWER

The STR9 device uses two Flash memories: Main Flash (Bank0) and Secondary Flash (Bank1). By default Bank0 is at boot location (address 0x0). By setting the CSX (Chip Select Mapping), Bank1 is selected as boot location (address 0x0). When you set the CSX bit, you must use the ICP algorithms for Flash download.

To boot from Flash Bank1 you must perform following changes:

  1. In file STR91x.s, change Flash Memory Interface (FMI)
     Flash Boot Bank Enable        checked
      - Boot Bank Size Configuration (BBSR)
          BBSize: Memory size      32KB
      - Boot Bank Base Address Configuration (BBADR)
          BBADDR: Address          0x000000
     Flash Non-boot Bank Enable    checked
      - Non-boot Bank Size Configuration (BBSR)
          BBSize: Memory size      512KB
      - Non-boot Bank Base Address Configuration (BBADR)
          BBADDR: Address          0x400000
    
  2. For file STR91x.s under Options — ASM — Define, define BOOT_BANK1.
      Define: BOOT_BANK1
    
  3. Add file STR91xCFG.s to your project and set CSX bit.
     Configuration
        CSX (Chip Select Mapping)  checked
    
  4. In your project under Options — Target, change settings for Read/Only Memory Areas.
     IROM1: Start 0x000000  size 0x8000
     IROM2: Start 0x400000  size 0x80000
    
  5. In your project under Flash Download Setup, change Flash Programming Algorithm to the ICP algorithms. All selected algorithms must be consistent using the ICP interface.
      STR91xFxx Flash Bank1 ICP
      STR91x CFG & Security ICP
    

The attached Blinky project shows the configuration for booting from Flash Bank0 or Flash Bank1.

ATTACHED FILES

Request the files attached to this knowledgebase article.

FORUM THREADS

The following Discussion Forum threads may provide information related to this topic.

Last Reviewed: Wednesday, September 05, 2007


Did this article provide the answer you needed?
 
Yes
No
Not Sure