Open Trace (Bit Array) VI
- Updated2024-11-20
- 4 minute(s) read
Opens a trace in a Citadel database to allow writing. Use the Close Trace VI to close the reference opened by this VI. You must manually select the polymorphic instance to use. If you do not wire the database URL parameter, this VI writes data to the database associated with the default LabVIEW Datalogging and Supervisory Control (DSC) Module process. This VI returns an error if there is already an active writer for the selected trace.
Use the pull-down menu to select an instance of this VI.

Inputs/Outputs
timeout (30 s)
—
timeout limits the time that this VI waits when contacting the Citadel database. The default is 30 seconds. A timeout value of less than or equal to 0 indicates no timeout, and this VI waits indefinitely until this VI receives data from the Citadel database.
database URL
—
database URL specifies the computer name and the database name where the Citadel database resides. Enter the database URL in the format \\computer\database.
process name
—
process name is the name of the group to which this trace belongs. This parameter must be a string of numbers and letters with or without spaces.
trace name
—
trace name is the name of the Citadel trace. If a trace with this name does not exist in the target database, the DSC Module creates a new trace. Otherwise, Citadel appends data to the end of the existing trace.
error in (no error)
—
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
trace attributes
—
trace attributes contains information about trace attributes.
lifespan in days (use current lifespan)
—
lifespan in days specifies the number of days that LabVIEW stores a trace in the Citadel database. The default is --1, which means lifespan in days is the lifespan of the current process or is infinite if the current process does not exist. Only one writer in a process can set lifespan in days. If multiple writers are open, Citadel allows only the first writer in the process to set lifespan in days.
trace reference
—
trace reference is the refnum associated with the open writer. If this VI fails, trace reference returns Not A Refnum.
database URL out
—
database URL out returns the computer name and the database name that specify where the Citadel database resides. The format is \\computer\database.
error out
—
error out contains error information. This output provides standard error out functionality. |
Examples
Refer to the Database Direct Write Demo.lvproj in the labview\examples\lvdsc\Data and Alarm Historical Logging\Database Direct Write Demo directory for an example of using the Open Trace VI.
timeout (30 s)
—
database URL
—
process name
—
error in (no error)
—
trace attributes
—
time precision
—
trace reference
—
database URL out
—
error out
—