Consider this example code. This was developed in National Instruments LabWindows,
using the IVISwtch driver.
static ViStatus s; // Status returned from calls
static ViSession h; // Instrument handle
s = IviSwtch_init (
“SwitchLogicalName”,
// Set the Logical_name using NI’s MAX –
// Measurement and Automation Explorer
VI_TRUE,
// Query the device
VI_TRUE,
// Reset the device
&h);
IviSwtch_Connect (h, "1", "1c"); // Close relay 1
s = IviSwtch_close (h);
For a simple example showing the IVI driver, see example-ivi.c. To learn the complete
IVI Swtch driver, load the files in the IviSwtch subdirectory (usually installed at
C:\Program Files\IVI) into NI LabWindows and explore the detailed help of the
“Function Panel”.
National Instruments LabVIEW
There are two methods to program the TAMS Switches in LabVIEW. The first is to use
Direct IO commands sent directly to the device. See the Direct IO section above for
more information on this method.
The second method is to convert the supplied IVI driver to a LabVIEW driver and
program calls to this converted driver. For this method, follow these steps:
1. Install the IVI driver as described above in section “IVI Device Specific Driver”.
2. Create a LabVIEW driver from the IVI driver.
- 17 -
Содержание 1800 Series
Страница 1: ...TAMS 1800 Series USB Controlled Switches Installation Operation 1...
Страница 4: ...Declaration of Conformity 27 4...
Страница 9: ...9...
Страница 28: ...TAMS 1800 Series USB Controlled Switches Printed in USA Revision 1 0 Part 1800 90002 28...