02.03.2014 Views

BSP Developer's Guide

BSP Developer's Guide

BSP Developer's Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

2<br />

<strong>BSP</strong> Organization<br />

Version 1.0 <strong>BSP</strong>s are written for all standard VxWorks releases up to and including<br />

VxWorks 5.2. Version 1.1 <strong>BSP</strong>s are written for Tornado 1.0 and Tornado 1.0.1.<br />

Version 1.2 identifies a <strong>BSP</strong> designed for use with Tornado 2.x. The main interface<br />

differences between 1.1 and 1.2 <strong>BSP</strong>s is support for the networking stack and<br />

different packaging. With each new version sequence, the revision number begins<br />

with 0 and is incremented each time the <strong>BSP</strong> is released for production.<br />

To specify a <strong>BSP</strong> version number, you can define <strong>BSP</strong>_VERSION to be the string<br />

“1.2” or “1.1”. Otherwise, you can define either of the macros <strong>BSP</strong>_VER_1_1 or<br />

<strong>BSP</strong>_VER_1_2, whichever is appropriate. To set the revision number, use <strong>BSP</strong>_REV,<br />

which you should set to a string value such as “/0”. The revision number includes<br />

the slash character. The full <strong>BSP</strong> release number is the concatenation of the two<br />

string macros <strong>BSP</strong>_VER and <strong>BSP</strong>_REV: for example, “1.2/0”.<br />

Thus, to set a <strong>BSP</strong>’s release number to “1.2/0”, define the following:<br />

2<br />

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

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

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

#define <strong>BSP</strong>_REV "/0" /* Increment for each new release */<br />

configAll.h. Include configAll.h (located in the target/config/all directory) in your<br />

config.h so the reasonable configuration defaults for a <strong>BSP</strong> are adopted. Use<br />

config.h as the main user-editable configuration file for your <strong>BSP</strong>.<br />

Use config.h as the main user-editable configuration file for your <strong>BSP</strong>. To pick up<br />

the reasonable configuration defaults for a <strong>BSP</strong> at your site, your config.h should<br />

include configAll.h (located in the target/config/all directory). 1<br />

Within your config.h you can override these site defaults, with values more<br />

appropriate to this particular <strong>BSP</strong>. You should also present your config.h to<br />

subsequent users of your <strong>BSP</strong> as the configuration file that they should edit either<br />

to override configAll.h or to configure whatever optional features you have built<br />

into your <strong>BSP</strong>.<br />

When building project images, components and parameters selected using the<br />

project override any values assigned in either configAll.h, config.h, or even<br />

bspname.h. Any macro known to the project facility is assigned the project value,<br />

overriding any other assignment.<br />

1. Here, the term “user” refers to developers who use your <strong>BSP</strong> to build their VxWorks applications.<br />

In addition, if a value is not optional but always required and must not be edited,<br />

set it in bspname.h, not config.h.<br />

17

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

Saved successfully!

Ooh no, something went wrong!