In-System Programming Support > ARM Cortex

Important Change Regarding Code Read Protection

(1/1)

Andy Ayre:
Previously code read protection was enabled by checking a box in the main window of Flash Magic. This supported only level 2 of CRP.

Starting with Flash Magic 5.11 the code read protection setting is read from the hex file and all CRP levels are supported. If an attempt is made to set the device to CRP3 then the user is prompted for confirmation.

To set the CRP value in your project add something like the following (Keil RealView example):


--- Code: ---const unsigned long crp __attribute__ ((at(0x1FC))) = 0x87654321;
--- End code ---

or:


--- Code: ---const unsigned long crp __attribute__ ((at(0x2FC))) = 0x87654321;
--- End code ---

If you don't wish to use CRP then set the value to zero.

If you have previously programmed hex files without problems and now find that you cannot read the contents of memory or access a few other features then this change is the likely cause. Erase all the flash in the device and add the above line (or similar).

Andy

Navigation

[0] Message Index

Go to full version