Click or drag to resize

Visual Studio Projects for an IVI-C Driver

Nimbus supplies two custom project types to the Visual Studio project system that enable IVI-C driver development, documentation, and installation.

  • IVI-C Driver Help Project

    This project type is used to build the driver help file(s) for an associated IVI-C driver. Each help project is associated with a single IVI-C driver project, and includes the help template files used to control the look and feel of the driver documentation being produced. A driver help project may be created by the IVI-C Driver Wizard based on your selections, or added to the driver solution later.

  • IVI-C Driver Setup Project

    This project type is used to build the driver installer for an associated IVI-C driver. Each setup project is associated with a single IVI-C driver project, and includes the WiX source files used to produce the driver installer (MSI). A driver setup project may be created by the IVI-C Driver Wizard based on your selections, or added to the driver solution later.

In addition to the above custom project types, Nimbus also supports adding two standard Visual Studio project types to a driver solution.

  • Unit Test Project

    This is a standard Visual Studio project type that enables unit testing of IVI-C drivers. Although Nimbus leverages the standard Visual Studio unit testing framework, the Nimbus driver automatically adds and removes unit test methods from this project as you interact with the Nimbus driver designer.

  • C++ Console Application

    This is a standard Visual Studio project type for building a C++ console application that exercises the IVI-C driver. After adding this type of project to a driver solution, Nimbus performs no further modifications. This provides a convenient way to create a starter application associated with your driver that can be used for additional testing or as sample code.

Nimbus-Managed Files

There are a number of files in a Nimbus driver project that are automatically updated as part of the Nimbus roundtripping logic. For instance, when new functions or attributes are added to a driver, the <prefix>.h file must be updated with the appropriate function definition or macro definition. Nimbus automatically updates this file, so it is important that users never manually make changes to such files. These are referred to as Nimbus-managed files. Most files in an IVI-C driver project are Nimbus-managed files.

Important note Important

Any manual changes made to any Nimbus-managed file will be automatically overwritten by Nimbus whenever the driver project is edited. It is important to never directly edit a Nimbus-managed file.

The following files in an IVI-C driver project are Nimbus-managed files:

  • Attributes.cpp

  • Attributes.h

  • DriverInfo.cpp

  • Enums.h

  • Enums.cpp

  • Errors.cpp

  • Models.cpp

  • RepCaps.h

  • <prefix>.h

  • <prefix>.fp

  • <prefix>.sub

  • <projectName>.def

There are only a two driver files that a driver developer generally needs to edit -- <prefix>.cpp file and the DriverSession.h file. The former contains nearly all of the implementation code for the IVI-C driver's functions and attributes, while the latter is sometimes needed to customize the default implementation Nimbus supplied for certain driver features.

Managing Multiple Drivers in a Solution

In some situations, it may be desirable to manage multiple IVI drivers in a single solution. Since a Nimbus IVI driver project is simply another type of Visual Studio project, this can be supported using standard Visual Studio techniques.

To add a Nimbus driver project to an existing solution

  1. From Solution Explorer, right-click on the Solution node.

  2. Choose Add and then either New Project... or Existing Project....

  3. For a new Nimbus IVI driver project, choose Nimbus Projects from the New Project Wizard and proceed as usual with the New IVI-C Driver Wizard. For an existing Nimbus IVI driver project, browse to the .vcproj file for the desired driver.

  4. The added Nimbus IVI driver project will be loaded into Visual Studio with all of its associated projects -- setup, installer, unit test, etc. A separate Nimbus node with its subnodes will appear in Solution Explorer.

Download a complete CHM version of this documentation here.