User`s manual

Rabbit 4000 Designer’s Handbook rabbit.com 41
6.4.1 Macros that Affect the BIOS
There are several macros that may be modified for custom-designed boards or for special situations
involving off-the-shelf Rabbit 4000-based boards. The following list is not exhaustive.
CLOCK_DOUBLED
Default value of 1 causes the clock speed to be doubled. Setting this to zero means the clock speed will not
be doubled.
To override the default, define CLOCK_DOUBLED to zero in the project by using the Defines tab of the
Project Options dialog.
CS1_ALWAYS_ON
Default value of 0 disables the feature of keeping /CS1 always active.
To override the default, define CS1_ALWAYS_ON to 1 in the project by using the Defines tab of the Proj-
ect Options dialog. Keeping /CS1 always active is useful if your system is pushing the limits of RAM
access time. It will increase power consumption a little.
DATAORG
This macro is deprecated. Use ROOT_SIZE_4K instead.
ROOT_SIZE_4K
This macro defines the number of 4 kilobyte pages used for the base segment. The default is 3 when sepa-
rate I&D space is enabled, and 6 otherwise.
To override the default, define ROOT_SIZE_4K in the project by using the Defines tab of the Project
Options dialog. Increasing this value increases the size of root constants when separate I&D space is
enabled, and root code when it is disabled.The sum of available root and data is constant, such that
increasing one decreases the other. This macro can be changed to as high as 11 and as low as 1 when sepa-
rate I&D space is enabled or as low as 3 when separate I&D space is disabled.
ENABLE_CLONING
Default value of 0 disables cloning.
To override the default, define ENABLE_CLONING to 1 in the project by using the Defines tab of the
Project Options dialog. This slightly increases the code size of the BIOS.
If cloning is used, PB1 should be pulled up with 50K or so pull-up resistor. On some Rabbit core modules,
such as the RCM4200, the PB1 (CLKA) signal is either not available or not pulled up on the programming
port. The master can be forced to invoke cloning support by setting CL_FORCE_MASTER_MODE to 1.
This will cause the BIOS to assume a cloning cable is attached on every startup, assuring that only the
cloning code will run. Note that defining CL_FORCE_MASTER_MODE to 1 will not allow the program on
the board to run, that is, the board will act only as a clone master.
While compiling to the target with CL_FORCE_MASTER_MODE set to 1, the loss of target communication
is expected and unavoidable. After the program has loaded and target communication is lost the clone mas-
ter will still correctly perform its cloning function after a cloning cable is attached.
Various cloning options are available when ENABLE_CLONING is set to one. For more information on
cloning, please see Chapter 8, “BIOS Support for Program Cloning,”in this manual and/or Technical Note
207,Rabbit Cloning Board,” available at rabbit.com.