LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

gpib polling

My question pertains to opening labview vi's. In my application I am connected to many test instruments through a gpib bus. When I launch a labview vi program the program opens and no polling of the instruments occurs until I run the vi program. I have noticed on the subvi's however when I launch them before I run them polling occurs and all of my instruments go into remote mode before I run these programs. So basically some vi's that I run automatically put all the instruments in remote mode before running the vi even instruments that are not being accessed in the vi (if it is on the bus it goes into remote) and others do not put them into remote until I access them. Is this a setting somewhere in these vi's that is doing this? I would prefer to not have these put in remote automatically because of time constraints as the polling is not instantaneous. 
 
Thanks   
0 Kudos
Message 1 of 4
(2,663 Views)
Someone may have set some of the VIs to "Run when Opened." A VI does absolutely nothing until it is run. Why someone would set a subVI that way is a bit of a mystery. It is common to make top level (main) VIs run that way so users don't have to start them up.

If you cannot figure out what is happening, post one of the VIs which exhibit this behavior.

Lynn
0 Kudos
Message 2 of 4
(2,659 Views)

Hi Lynn

Thanks for helping

Here is one vi that exhibits this property. The vi does not run when opened. Upon opening the vi the instruments go into remote mode automatically.

 

Mark

 

 

 

0 Kudos
Message 3 of 4
(2,653 Views)
Where did you get this VI?  It should be scrapped, as it makes no sense. It's got a VISA resource control, but it's not even using VISA functions. Rewrite the VI using VISA. Also, the "error out" should not be inside the case. It should be outside, with the error cluster wired through.

Sorry, had to say that...

As for your question, I can't see how this VI would produce the behavior you're describing. I had NI Spy running when I opened the VI and I saw no traffic. Just for the heck of it I changed the VISA resource to TCP/IP and saw no traffic on a packet sniffer either.
0 Kudos
Message 4 of 4
(2,636 Views)