beautypg.com

Sample vis – Crystal XP2i-DP Digital Differential Pressure Gauge User Manual

Page 9

background image

Virtual Instruments

9

XP2i LabVIEW Drivers Manual

samPle VIs

Two VIs are provided as examples of how to use the XP2i library. They are

XP2i Test Panel.vi and XP2i Collect Pressure Point.vi.

XP2i test Panel.vi

This top level VI demonstrates the use of each of the VIs within the library. It also demonstrates a sample data collecting loop, including the graphing of the
pressure or mA readings from the unit. As it is a top level VI, it has no inputs or outputs.

The COM Port numeric control should be set to the proper COM port prior to executing the VI. To stop executing, press the Stop button on the VI. Do not use
the LabVIEW stop command, as it will leave the serial port open until LabVIEW is exited, or the VI is rerun and its stop button is pressed.

XP2i collect Pressure Point.vi

This VI is a simple data collection VI that calls XP2i Pressure Query.vi and appends the result to the Data array.
Time stamps are based off of the Start time (tick count) input.

X

Inputs and outputs

Start Time . . . . . . . . . . . . . . . . . . . . . . . The start of data collection, in milliseconds.

Data In . . . . . . . . . . . . . . . . . . . . . . . . . . Input 2xN array of data elements.

Data Out . . . . . . . . . . . . . . . . . . . . . . . . Output 2xN array of data elements. The XP2i pressure reading added to the end, with column one equal to the current tick

count minus the Start time (tick count) input, and column two equal to the sensor reading.

This manual is related to the following products: