LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to choose the serial port if only the run time engine is installed

I have an application, which communicates over the serial port. When I use the full version of Labview I can change the serial port without any problem from Com1 to Com2 (similar to the example “Hardeware input output -> serial -> Labview serial vi"). When I build an application and try to run this program on a computer where only the run time engine 6.1 is installed, it is not possible to choose the serial port. Since there is no “Measurement and Automation Explorer” available on the run time engine and no directory C:\VXIpnp is created, when the run time engine is installed, I do not see a way, how I can satisfy the computer with the information it needs for configuring
the different ports. Any suggestions?
0 Kudos
Message 1 of 5
(3,022 Views)
Hi Daniel,

Before LV6.1 there was LV5.1 In LV5.1 the way to Spedify a resource was to use a string control with correct VIsa Resource Class identifier. For eg. "GPIB0::11" or "ASRL1::INSTR". With Introduction of VISA Resource Name Control and linking with MAX, These names are Available from Pull Down List and Can be Aliased, meaning ASRL1 which is Serial Port 1 can be called COM1 and so on. However the old method still works with all 6.1 Controls. Only thing is you have to make sure you Dont Conflict the Class Names ie Use "GPIB::.." instead of "ASRL..." when addressing Serial Port VI's.

To solve your Problem I would Build a Menu ring with COM1 to COM4 in the Pull Down List.

Next, If I use the Traditonal Serial Port VI wich accepts the Integer as Seria
l Port #. I just Wire the Menu Ring to this VI.(Remember COM1 is 0, COM2 is 1 for this VI)

If I use VISA Config Serial Post. I build an Array Constant with Corresponding VISA Class Names So in our case a String Array Constant of 4 elements "ASRL1::INST" to "ASRL4::INST". I Use Index Array Function With the Index Wired to my Menu Ring. The Array Input Terminal Wired to the Array Constant. The Output of this Array will be correct Visa Class Name Based on slection of my Menu Ring. I can Wire this as Input to my VISA Config Serial Port Vi.

I have attached a Small VI to Illustrate this.

Drawback: You must Predefine what Ports you will Want to Use. Basically you define all the cases.

I hope this Answers your Q!

Good Luck

Mache
Good Luck!

Mache
0 Kudos
Message 2 of 5
(3,022 Views)
Daniel,

If you use VISA functions for your application, then you should also install the VISA Run-time Engine as well.

Randy Hoskin
Applications Engineer
National Instruments
http://www.ni.com/ask
0 Kudos
Message 3 of 5
(3,022 Views)
Randy
Where can I get the VISA Run-time Engine?

I get the Run-time Engine from:
http://digital.ni.com/softlib.nsf/webcategories/85256410006C055586256BBB002C130D?opendocument&node=132070_US
0 Kudos
Message 4 of 5
(3,022 Views)

NI-VISA Run-time Engine.

You were looking at the LabVIEW Run-time Engine. You want the VISA Run-time Engine under the VISA link.

Randy Hoskin
Applications Engineer
National Instruments

0 Kudos
Message 5 of 5
(3,022 Views)