You must construct source Excel spreadsheets for FlexLogger projects in a specific way to use them with the Spreadsheet Importer.

FlexLogger expects project source spreadsheets to store data in specific sheet and column names. You can create a source spreadsheet using FlexLogger or the command line to ensure the spreadsheet contains the names FlexLogger expects. Once you create a source spreadsheet, you can remove any template sheets and columns you do not need for your project.
Note FlexLogger can only process source spreadsheets if the sheet names, column names, and values are in English.

Creating a Template Spreadsheet Using FlexLogger

You can create a template project spreadsheet from within FlexLogger.

  1. Navigate to File » Copy empty spreadsheet template.
  2. Specify the file path where you want to save the template spreadsheet.

Creating a Template Spreadsheet Using the Command Line

You can create a FlexLogger project spreadsheet without opening FlexLogger by using the command line.

  1. Open a command prompt, terminal, or PowerShell window.
  2. Enter cd "C:\Program Files\National Instruments\FlexLogger\" to navigate to your FlexLogger installation location.
  3. Run ./flexloggercli.exe createtemplate with the following arguments to create your spreadsheet.
    Table 18. Spreadsheet Template Creation Command Line Options
    Argument Description
    -f Specifies the file path you want to save the spreadsheet to.
    -n Specifies the spreadsheet name.
    -o Optional argument that overwrites any existing spreadsheets with the same name at your specified path.
If you run the following command:
./flexloggercli.exe createtemplate -f "C:\Users\nitest\Documents\FlexLogger\ImporterProjects" -n "MyTemplate" -o

The Spreadsheet Importer creates a spreadsheet named MyTemplate.xlsx at C:\Users\nitest\Documents\FlexLogger\ImporterProjects\MyTemplate.xlsx.

Populating Your Spreadsheet with Data

Once you have created your template spreadsheet, you can populate it with the hardware and channel information relevant to your project.

Specifying Hardware in Your Spreadsheet

Use the Channel Mapping sheet in your spreadsheet to define your channels and what hardware those channels are on. Consult the following table for information on hardware channel properties.
Table 19. Channel Mapping Columns
Column Name Definition
Channel Name User-defined channel name.
Chassis Model Type of chassis, such as "NI PXIe-1083" or "NI cDAQ-9189".
Chassis Name Name of the chassis defined in NI MAX or Hardware Configuration Utility.
Chassis Serial Number (Optional) Chassis serial number.
Module Slot Number The chassis slot containing the module. For FieldDAQ devices, this value is the bank number the channel is on.
Module Model Type of module, such as "NI PXI-6289" or "NI 9205 (DSUB)".
Module Name Name of the module defined in NI MAX or Hardware Configuration Utility.
Physical Channel Name of the channel, such as "AI0" or "port0/line2".

The following table contains examples of valid definitions for hardware channels. You only need to define the populated properties for each channel type to define hardware using that method.

Table 20. Example Hardware Configurations
Channel Type Channel Name Chassis Model Chassis Name Module Slot Number Module Model Module Name Physical Channel
Chassis-defined channel Channel1 NI PXIe-1083 MyPXIChassis 2 NI PXI-6289 port1/line2
Module-defined channel Channel2 NI 9219 MyModule AI3
Onboard cDAQ chassis counter Channel3 NI cDAQ-9189 MyDAQChassis CTR0
FieldDAQ channel Channel4 1 NI FD-11614 MyFieldDAQ AI0

Determining Valid Values

Source spreadsheets created based on the provided template have data validation in all columns where only specific sets of values are valid.
  • Certain columns only accept values from a set list. These columns show the values they can accept when you try to populate them. For example, the Coupling column only accepts AC or DC as valid values.
  • Certain columns must contain a numerical value.
  • The following columns require specific value formatting:
    • You must format values in the Data Rate column as Level (Hertz Value). For example, you can define your channel data rate as Medium (100) or Slow (5).
    • You must format values in the Signal Range and Hardware Range columns as either Automatic or Manual (Min; Max). For example, you can define a signal range as Manual (-10; 10).
    • You must format values in the Critical Range and Warning Range columns as (min; max). For example, you can define a critical range as (-20; 20).
Note Formulas you define in the Formula column must adhere to FlexLogger formatting, so you must surround channel names with single quotes (Ex. 'channelName'). However, if your formula begins with a channel name, you must begin your formula with two single quotes in a row to preserve the formatting (Ex. ''channelName' < 10).

If you enter an invalid value in a column, the Spreadsheet Importer output includes an error or warning which describes how to fix the invalid configuration.

Example Spreadsheets

FlexLogger comes with two example spreadsheets, which install at C:\Program Files\National Instruments\FlexLogger\Examples\Spreadsheet Importer by default. The following table lists the examples and their features.
Table 21. FlexLogger Spreadsheet Importer Shipping Examples
Example Name Description
ChannelConfigurationReference.xlsx This example contains at least one configured channel for each measurement type, which demonstrates valid values and how to fill out your source spreadsheet.
SimpleExample.xlsx This spreadsheet contains 12 configured channels, and demonstrates what your source spreadsheet could look like. Some sheets and columns are not used in this example, so they have been deleted.