Datasheet

PSoC Designer IDE Guide, Document # 001-42655 Rev *B 151
B.4 Examples
B.4.1 Batch Build File
This is a .bat file that builds a project; here PSoC Designer is installed in c:\a\pd
set PSOCTOOLS=c:\a\pd\tools
set PATH=%PSOCTOOLS%;c:\winnt\system32;c:\winnt
set DEVICE=CY8C24423B
set BASEDEVICE=CY8C24000B
set LASTROM=0xFFF
make -f %PSOCTOOLS%\Makefile clean
make PROJNAME=aa -f %PSOCTOOLS%\Makefile makemake
make –f %PSOCTOOLS%\Makefile depend
make -f %PSOCTOOLS%\Makefile
B.4.2 Boot Loader Example
This ‘make’ trick allows a project to have a block of RAM that is shared between a boot-loader and
the boot-loaded code. This trick tells the linker to begin RAM allocation at some point other than
location 0. In this example we will have this RAM scratch pad area from RAM address 0 to 4.
In the project's local.mk file add a ‘new’ MAKE variable as follows:
STARTRAM:=0x5
In the project’s local.dep file add this line:
DATARAM:=-bdata:$(STARTRAM).0xFF
Now in your boot loader code use an absolute RAM area to declare variables in this ‘hidden/shared’
area like:
AREA Foo(RAM,ABS)
ORG 0
export _Z1, _Z2, _Z3, _Z4
_Z1: blk 1
_Z2: blk 1
_Z3: blk 1
_Z4: blk 2