Building and Deploying a Stand-Alone Real-Time Application (Real-Time Module)

LabVIEW 2017 Real-Time Module Help

Edition Date: March 2017

Part Number: 370622R-01

»View Product Info
Download Help (Windows Only)

Complete the following steps to build a stand-alone real-time application and deploy it to an RT target:

Note  
  1. Open the project you want to use to build the stand-alone real-time application.
  2. Right-click Build Specifications under the RT target and select New»Real-Time Application from the shortcut menu to display the Real-Time Application Properties dialog box.
  3. Complete the following items on the Information page of the Real-Time Application Properties dialog box:
    1. Enter a name for the build specification in the Build specification name text box. This name appears under Build Specifications. The name must be unique among other build specification names under the RT target.
    2. Enter a name for the stand-alone real-time application in the Target filename text box. Stand-alone real-time applications must have a .rtexe extension.
    3. Explore the remaining items on the Application Information page.
  4. Complete the following items on the Source Files page:
    1. In the Project Files tree, select the VI you want to define as a startup VI, also known as a top-level VI, for the stand-alone real-time application. Startup VIs open and run when you power on the RT target. You must define at least one VI as a startup VI for each stand-alone real-time application you build.
    2. Click the right arrow button next to the Startup VIs listbox to move the selected VIs into the Startup VIs listbox.
    3. In the Project Files tree, select the items you want to define as dynamically called VIs or support files, such as VIs you want to call using the VI Server or text files that you read from a VI.
    4. Click the right arrow button next to the Always Included listbox to move the selected items into the Always Included listbox.
Note  You cannot include a polymorphic VI in the Startup VIs or Always Included listboxes. Use an instance of the polymorphic VI instead.
  1. On the Destinations page, configure destination settings and add destination directories for the stand-alone real-time application.
  2. From the Source File Settings page, edit destinations and properties for individual files and folders in the stand-alone real-time application.
    Note  If you plan to distribute a stand-alone application that uses shared variables, do not include the .lvlib file in an LLB or in the executable. Change the Destination of the .lvlib file to a destination outside the executable or LLB.
  3. On the Advanced page, configure advanced settings for the stand-alone real-time application.
  4. On the Additional Exclusions page, configure settings to reduce the size of the stand-alone real-time application, improve load time, and reduce memory usage when you load the resulting build.
  5. On the Pre/Post Build Actions page, specify VIs for LabVIEW to execute before or after the build.
  6. On the Preview page, click the Generate Preview button to review the generated files for the stand-alone real-time application.
    Note  Save changes to VIs in memory before you create or edit a build specification to ensure that the preview is accurate.
  7. Deploy the application from the Project Explorer window or outside of the LabVIEW development environment.

Deploying from the Project Explorer Window

Complete the following steps to build a stand-alone application and deploy that application to an RT target from the Project Explorer window:

  1. Use the Real-Time Application Properties dialog box to specify settings for the application.
  2. Click the Build button. The build specification name appears in the project in the Build Specifications tree under the RT target in the Project Explorer window, and LabVIEW places the application in the directory you specified on the Destinations page of the Real-Time Application Properties dialog box.
  3. Right-click the build specification and select Set as startup from the shortcut menu.
    Note  You can create multiple build specifications that configure the settings of stand-alone real-time applications under an RT target. However, you can set only one stand-alone real-time application as startup for an RT target. When you set a build specification as the startup application for an RT target, LabVIEW displays a green border around the icon for the build specification in the Project Explorer window.
  4. Right-click the build specification and select Deploy from the shortcut menu to deploy the application to the RT target.
  5. Right-click the RT target and select Utilities»Restart to reboot the RT target and run the stand-alone real-time application.
Note  You cannot run a stand-alone real-time application without setting the application as startup and rebooting the RT target.

Deploying from outside of the LabVIEW Development Environment

Complete the following steps to deploy a stand-alone real-time application from outside of the LabVIEW development environment:

  1. Use the Real-Time Application Properties dialog box to specify settings for the application.
    Note  You must specify at least one startup VI from the Source Files page.
  2. On the Component Definition page, place a checkmark in the Create a component definition file (.cdf) and specify dependencies checkbox.
  3. (Optional) If you want to specify a version number for the application, remove the checkmark from the Auto increment checkbox in the Version Number panel and specify a version number for the application.
  4. (PXI) In the Required software components list, place a checkmark in the checkbox next to each software component that you need to install alongside the application. Choose between the available versions of each software component with the Software version pull-down menu.

    (CompactRIO) Select the software set you need to install alongside the application in the Required software set list. In the Addons list, place a checkmark in the checkbox next to each addon you want to install. (Optional) Remove the checkmark from the Show software by set checkbox to view a list of available software components instead.
    Note   LabVIEW always specifies the version of the LabVIEW Real-Time Module that you are running as a dependency of the application.
  5. Click the Build button. LabVIEW builds the application and a component definition file (.cdf), which defines the application and its dependencies. LabVIEW places the .cdf in the National Instruments\RT Images\User Components directory.
  6. When the build completes, review the location of the built application in the Build status dialog box and click the Done button.
  7. Install the application and its dependencies to a small number of targets using NI Measurement & Automation Explorer (MAX) or a large number of targets using the Install Startup instance of the Install VI. Refer to the Installing a Startup Application topic in the Measurement & Automation Explorer Help for steps to install a stand-alone application using MAX.

For more information about deploying stand-alone real-time applications from outside the LabVIEW development environment, refer to Using Application Components to Deploy LabVIEW Real-Time Applications, available on ni.com.

WAS THIS ARTICLE HELPFUL?

Not Helpful