Admin Production ni-theme
Current Publication

About Loadable Compiled Modules

LabWindows/CVI

About Loadable Compiled Modules

Several methods exist for using compiled modules in LabWindows/CVI. You can load compiled modules directly into the LabWindows/CVI environment as instrument driver programs or as user libraries, so they are accessible to any project. You can list compiled modules in your project so they are accessible only within that project. Any compiled module you use in LabWindows/CVI must be in one of the following forms:

  • A .obj file that contains one object module
  • A .lib file that contains one or more object modules
  • A .dll file that contains a Windows DLL

You can create any of these compiled modules in LabWindows/CVI or in a compiler that generates files of the Common Object File Format (COFF).

Advantages and Disadvantages of Using Loadable Compiled Modules in LabWindows/CVI

Using compiled modules in LabWindows/CVI has the following advantages:

  • If an instrument driver program file is a source module and the source module is not in the project, LabWindows/CVI recompiles it each time you load the instrument driver. LabWindows/CVI does not recompile compiled modules each time you load an instrument driver.
  • You can dynamically load compiled modules, but not source modules, in executables.
  • You can install compiled modules, but not source modules, into the Library Tree.
  • You can provide libraries for other developers without giving them access to your source code.

Using compiled modules in LabWindows/CVI has the following disadvantages:

  • You can debug only .dll files created in LabWindows/CVI. You cannot debug other types of compiled modules, such as .dll files created outside of LabWindows/CVI, .obj files, or .lib files because these compiled modules do not contain debugging information.
  • Only .dll files created in LabWindows/CVI contain run-time error checking or user protection. Other types of compiled modules, such as .dll files created outside of LabWindows/CVI, .obj files, or .lib files do not.