02.03.2014 Views

BSP Developer's Guide

BSP Developer's Guide

BSP Developer's Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

VxWorks 5.5<br />

<strong>BSP</strong> Developer’s <strong>Guide</strong><br />

HEX_FLAGS<br />

Architecture-specific flags for the objcopy utility that generates S-record files.<br />

MACH_EXTRA<br />

Any extra machine-dependent files. Make it an empty declaration for now.<br />

! CAUTION: The hexadecimal addresses above should not include a leading 0x.<br />

bspname.h<br />

config.h<br />

sysLib.c<br />

Some additional architecture-specific macros might also be required in the<br />

makefile. For example, the i960 needs to know where to link the Initial Boot<br />

Record. For architecture-specific information, see the appropriate VxWorks<br />

Architecture Supplement or 4. Hardware <strong>Guide</strong>lines.<br />

See bspname.h, p.26.<br />

The basic description of config.h, p.16 applies, although some small modifications<br />

are needed. First, make sure the following code stub is present before the line that<br />

includes configAll.h:<br />

/* <strong>BSP</strong> version/revision identification, before configAll.h */<br />

#define <strong>BSP</strong>_VER_1_1 1<br />

#define <strong>BSP</strong>_VER_1_2 1<br />

#define <strong>BSP</strong>_VERSION "1.2"<br />

#define <strong>BSP</strong>_REV "/0" /* 0 for first revision */<br />

To start, add the following lines near the end of the header file:<br />

#undef INCLUDE_MMU_BASIC /* bundled mmu support */<br />

#undef INCLUDE_CACHE_SUPPORT /* cache support */<br />

Make sure the definitions of ROM_TEXT_ADRS, ROM_SIZE, and<br />

RAM_LOW_ADRS match those defined in the makefile.<br />

Make sure LOCAL_MEM_LOCAL_ADRS and LOCAL_MEM_SIZE are correctly<br />

defined.<br />

While sysLib.c is by far the largest <strong>BSP</strong> file, at this phase you should implement<br />

only the basics: sysModel( ), sysBspRev( ), sysHwInit( ), sysHwInit2( ), and<br />

sysMemTop( ). The routine sysBspRev( ) is new as of VxWorks 5.3. Implement this<br />

routine as follows:<br />

46

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!