Keil Logo

MCBSTR9: STR9 FLASH PROGRAMMING


Information in this article applies to:

  • RealView MDK V3.04
  • MCBSTR9 Evaluation Board

QUESTION

I would like to use the extended Flash capabilities of the STR9 devices. Is there a way to program the device using the ISP interface?

ANSWER

By default, new projects select the CPU algorithm (from the device database). This means the CPU programs the on-chip FLASH ROM.

However, you may also program the Flash ROM using the ICP interface. For the STR9 devices the following Flash programming algorithms are available:

  • STR91xFxx2/4 Flash Bank 0: programming via CPU
  • STR91xFxx2/4 Flash Bank 0 ICP: programming via ICP
  • STR91xFxxx Flash Bank 1: programming via CPU
  • STR91xFxxx Flash Bank 1 ICP: programming via ICP
  • STR91x OTP ICP: OTP area programming via ICP
  • STR91x User Code ICP: User code area programming via ICP
  • STR91x CFG & Security ICP: Configuration area programming via ICP

When advanced Flash features are required, then the ICP algorithms must be used. Usually the advanced Flash features are required in the production phase where security bits should be programmed before shipping the product.

Each method has benefits and disadvantages as outlined below:

Programming via CPU - Disadvantages

  • cannot program protected sectors in Bank 0 and 1
  • cannot program OTP, User Code, Configuration & Security Bit
  • cannot unlock a secured device
  • cannot be mixed with ICP programming in the same project

Programming via ICP - Disadvantages

  • cannot use Verify (due to a device problem)
  • cannot be mixed with other CPU programming algorithms which makes it impossible to program any other potential Flash devices connected to the external bus of the STR9 CPU
  • are slightly slower at 1MHz JTAG clock, however at 2MHz they have the same performance

Note:

  • The JTAG clock for CPU programming must be at least 8 times slower than the CPU clock (which is typically 25MHz XTAL). This means that you can typically select up to 2MHz JTAG clock).
  • ICP algorithms in Turbo Mode do not have that constraint but the Turbo Mode is not working completely due to a chip problem.

A programming example is provided as part of the RealView Microcontroller Development Kit (Version 3.04 or higher) in the folder ..\ARM\RV30\Boards\Keil\MCBSTR9\Blinky. When using the ICP algorithms, you may add a copy of the file ..\ARM\RV30\Startup\STR91xCFG.s to your application which allows programming of the OTP, User Code, Configuration Bytes, and Chip Security features.

MORE INFORMATION

  • Refer to Programming Flash in the MCBSTR9 User's Guide.
  • ST Microelectronic User's Manual for STR9 devices

FORUM THREADS

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

Last Reviewed: Monday, August 27, 2007


Did this article provide the answer you needed?
 
Yes
No
Not Sure
 
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.