1.13. Creating and Building a VxWorks 653-3.x Integration Project

In this tutorial we will create and build a project for Wind River VxWorks 653-3.x. We will create and build two partition operating system projects and one module integration project that encapsulates the two partition operating system projects.

Creating a VxWorks 653-3.x project for Ada development is easy with GNATbench and the Wind River wizards for creating 653-3.x projects. The wizards will create and configure the projects for us, with only a little subsequent manual configuration required. Invoking the builder is simply a matter of selecting a command, as usual.

1.13.1. Prerequisites

To use GNAT Pro and GNATbench for VxWorks 653-3.x you need to have the following:

  • Workbench for VxWorks 653-3.0.1 or later.
  • GNAT Pro High-Integrity Edition for PowerPC VxWorks6/Cert 7.4 or later
  • GNATbench for Workbench 2.10 or later.

This tutorial shows how to build the apex_raven example that is provided with the GNAT Pro High-Integrity Edition for PowerPC VxWorks6/Cert 7.4 or later compiler.

Note that in this tutorial, all new projects created through the Workbench wizards must be created in the same workspace.

1.13.2. Workspace Configuration

Start Workbench. Perspective Selection

Use the Window menu entry and select “Open Perspective”, then select “System Development”. Of course you may skip that step if you are already using that perspective.

1.13.3. Preliminary Project Setup

In order to ease the tutorial process, we will put all the required files from the apex_raven example into a general Eclipse project within the workspace. The sole purpose of this project is to act as a container for these files and to make these files easily accessible.

First create a new project by selecting New and then Project... to invoke the new-project wizard selection dialog, expanding the General category (if necessary) there, and then selecting Project under that, as shown below:


Press Next to choose that specific wizard.

In the resulting dialog box, name this new project “apex_raven” and click Finish. The new project will be created.

Next, import the files from the directory containing the example into the new “apex_raven” project. To do so, right-click on the “apex_raven” project node and select “Import...” from the contextual menu. In the resulting dialog box, select File System under the General category:


Press Next to invoke the File System wizard. You should then browse to the location of the example provided with your GNAT Pro High-Integrity

Edition for PowerPC VxWorks6/Cert 7.4 or later

installation. By default, this location would be “C:\GNATPRO\version#\share\examples\platform#\Workbench\apex_raven”, where “version#” is the GNAT Pro version you installed, such as “7.4.1”, for example; and “platform#” is “powerpc-wrs-vxworks”. The figure below shows the browser window and the selection of the “apex_raven” directory there:


Once you have selected the “apex_raven” directory press OK. Put a check-mark in the box next to “apex_raven” in the left-hand pane. The figure below shows the resulting wizard page:


Press Finish and the files will be imported into the “apex_raven” project in the workspace:


If you have imported the apex_raven/config/hardware.xml file, delete it since this file is not compatible with recent vxworks653 versions. After a minor manual update, all hardware.xml files created by Workbench are compatible with this tutorial.

1.13.4. Creating and configuring the Module Integration Project Create the Module Integration Project

Use the menu bar and select File, then New and then Wind River Workbench

In the resulting dialog box, set the target operating system to VxWorks 653 3.x operating system.


Click Next.

In the next page, select the build type to “Module Integration Project”


Click Next.

In the Project page, set the project name to “tutorial” and click Next.

On the Project Setup page


Set BSP to fsl_p3041_ds

Click Add...

Set the name of the partition to sender, and click OK.


Click again to the Add... button to add the receiver partition.


Click on Finish button to create the tutorial Module Integration project and the sender/receiver Partition Operating System projects. Import config files

If the config folder of apex_raven project contains the hardware.xml file, delete it before starting the import config files task.

Select the config folder of apex_raven project and then copy it to the clipboard.

Select the tutorial module integration project, and paste to the clipboard.

On the “Resource Exists” dialog, click to “Yes to All” to overwrite existing files.

If tutorial/config/hardware.xml file contains ‘uart0poll’ string, then apex_raven/config sender.xml & receiver.xml files should use a device named ‘uart0poll’.

<Device DeviceNameRef="uart0poll"/>

Otherwise, they should use a device named ‘uart0’.

<Device DeviceNameRef="uart0"/>

If it is required update the 2 xml files by changing DeviceNameRef attribute to the expected value.

Note: If sender.xml & receiver.xml are referencing ‘uart0poll’ device which is not part of hardware.xml devices, the tutorial build will fail with a “Device uart0poll does not exist” error. If sender.xml & receiver.xml are referencing ‘uart0’ device and ‘uart0poll’ is part of hardware.xml devices, the tutorial build will fail with an “Interrupt duart1 is assigned to multiple Partitions” error.

In apex_raven/config hardware.xml file, add MaxRefs attribute to the device used in sender.xml & receiver.xml files.

<Device Name="uart0" MaxRefs="unbounded">


<Device Name=”uart0poll” MaxRefs=”unbounded”>

Note: If the MaxRefs attribute is missing or invalid, the tutorial build will fail with a “Device uart0 or uart0poll is referenced more than 1 times” error.

Check that apex_raven/config init.xml, sender.xml & receiver.xml files contains “bootapp” strings for VxWorks 653 3.0.x target operating system or “bootapp_vt” for VxWorks 653 3.1.x target operating system. If it is required update the 3 xml files.

Note: If the wrong bootapp string is used, the tutorial build will fail with a “Cannot open bootapp or bootapp_vt file” error.

1.13.5. Configurating Partition Operating System Projects

There are two Ada applications in this apex_raven example: “sender” and “receiver”. Each application is located within a separate and dedicated Partition Operating System project.

The following steps are described for the “sender” application. Follow the same steps for the “receiver” application, replacing “sender”

by “receiver” in each instance. Configure sender/receiver kernel configuration

You should configure the kernel you have created to have it calling usrAppInit() (in your usrAppInit.c project file) after startup.

First open the sender kernel configuration editor. The menu to edit the kernel configuration is available in the sender project’s contextual menu.


Expand the application components node and quick include INCLUDE_USER_APPL component if not already included.


Save (Ctrl+S) the sender kernel configuration.

Do the same for the receiver kernel configuration. Import sender/receiver Ada Resources

Next, import the Ada sources from the sender application in the example to this new “sender” project.

Select all files/folder of sender folder of apex_raven project, and then copy them to the clipboard.


Select the sender partition operating system project, and paste the clipboard.


On the “Resource Exists” dialog, click to “Yes to All” to overwrite existing files.

Do the same copy/paste operation to import receiver Ada source files into receiver project. Configure sender/receiver for GNATbench Support

Next, the application projects should be configured to support Ada specific activities. This support requires the project to be configured for GNATbench use.

Right-click on the “sender” project to invoke the contextual menu, select New, then Other, expand the “Ada” category if necessary, and then finally select “Convert to an Ada Project”.


Press Next.

In the resulting dialog, specify “sender” as the project to convert.

On the same page, select “Use a local GNAT project file” and specify “sender.gpr”.

The wizard page, when filled out, will appear as illustrated by the figure below:


Click the Finish button and the project will be enhanced for GNATbench use. The project will appear as follows:


Do the same conversion for the receiver project. Checking sender/receiver projects

The projects should appear in the Project Explorer as follows:


~ Both projects should have the INCLUDE_USER_APPL component included in their kernel configuration. Set BINDING, PLATFORM and RUNTIME scenario variables

Open the Scenario Variables view (if not already open). To do so, first invoke the “Window” menu, then the “Show View” submenu. The Scenario Variables view may be presented in the list of views for opening directly, as shown below. If the view is not one of those presented for selection, press “Others...” and “Ada” to get to the Ada-specific views.


Select “Scenario Variables” and then press OK.

Once open, by default the view will appear in the same group as the Build Console, Problems, and Tasks views. See Scenario Variables View for how to set scenario variables in the view. Likewise, see Scenario Variables for the scenario variable concept itself.

Scenario variable can be set in two different modes: either “<set environment to use this value>” or “<set project specific value>”. In this tutorial, we will use the former.

Change the “BINDING” scenario variable from “apex” to “apex_1.3_zfp”. You will have to scroll down in the list of values to make that selection, as shown below:


Similarly, select “ravenscar-cert” for the “RUNTIME” variable in the Scenario Variables view. (Note that you may need to scroll down, as before, in the list of values).

Select also “powerpc-wrs-vxworks” for the “PLATFORM” variable.

Once set, the variables will look like the following in the view:

tutorial\_653\_3\_both\_apps\_scenario\_vars Build tutorial project

You are now ready to build the integration project. Right-click on the tutorial project node and select “Build Project” as usual.

You may be informed that the parallel builds have been enabled.


Click OK to continue the tutorial project build.

At the end of the build a “namespace warning : xmlns: URI ARINC653 is not absolute” error may be reported in tutorial project. Ignore it.


If build failed on “Cannot open bootapp or bootapp_vt file”.

  • remove the tutorial, sender & receiver projects
  • replace in init.xml, sender.xml & receiver.xml files of apex_raven/config folder “bootapp*” strings occurences with bootapp (VxWorks 653 3.0.x) or bootapp_vt (VxWorks 653 3.1)
  • rerun the tutorial.

1.13.6. Congratulations

That’s it! You have created and built a VxWorks 653 3;x Integration project with Ada applications.