User`s guide

Code & Data Management
AT85C51SND3Bx Firmware User’s Guide 4-19
7691A–MP3–08/07
4.1.2.3 How to activate code
banking?
Code banking enable are in the ‘Option for Targets’ pop-up in the Target tab.
Figure 4-5. Keil µVision ‘Option for Target’ window
Check the box “Code Banking” and select the maximum number of banks that
your application may have to support. For information, the banking frame code
size increases with the number of available banks. This number must be reported
in the file “lib_system\banking\l51_bank.a51” at the following definition
“?B_NBANKS EQU 4”.
Check that the “Bank Area Start” value matches with the one defined in the file
“option.has follows: “#define BANK_START_ADDRESS 0xC800”. This value
defined in the file “option.h” should not be modified since this common code (not
banked) is mainly the one of the Atmel system firmware.
Check that the “Bank Area End” value matches with the code range end address
defined in the tab “BL51 Locate”. This value, incremented by 1, must be also
reported in the file “option.h” at definition “#define XDATA_LENGTH …”.
The files building generates as many binary files as banks used with the following
extensions:
B00, B01, B02, … for binary bank files
H00, H01, H02, … for hex bank files
All the binary bank files are created in a 64K code space including the duplicated
common code.