08-11-2014 05:38 PM
Hi Community!
I'm new at this forum so forgive me if I posted this on the wrong section. I have multiple computers (1 local, 2 remote). The resource on all of these computers can be found by NI-VISA. My problem is that on the dropdown list, I can't figure out which resource comes from which computer. Is there any way to create a VI that does this? Maybe sort it by which computer the resource is from? I found the Find Serial Ports+Choose VI that's been posted around, however, this doesn't really solve the problem of differentiating which computer the resource is coming from.
Any help is appreciated. Thanks!
08-11-2014 06:03 PM
08-12-2014 10:53 AM
Hi Dennis_Knutson,
Thank you for replying. Yes. I can do that, however, that would mean I would have to manually changed the aliasing of each port on each computer, which would be okay if we're talking about just the 3 computers. But the purpose of the VI I'm designing is for multiple computers to interface that one kiosk computer. Is there any other options to do this besides the NI-VISA?
Thanks
08-12-2014 11:04 AM
Which computer do you actually care about and want to use the VISA serial port? I can only assume you are trying to use the serial port on the one kiosk computer. In which case I'd change the alias on that one to make it obvious.
08-12-2014 11:09 AM
Personally, I just use a configuration file to save my communication settings. Read the config file on startup, initialize your ports, and you are off to the races. If something is wrong, you'll quickly find out and you will need to fix your config file.
08-12-2014 11:16 AM
Hi RavensFan,
The way I'm setting up the kiosk (local) PC is that it will access the two PCs (2 remote). The two PCs are the ones connected to the devices through serial. All the kiosk does is run the VI, the two PCs are simply sending and recieving data from the devices to the kiosk. I attached a diagram for clarification. I've already established a way to communicate between all of the PCs, but when I use the VISA pallette, the connected ports doesn't differentiate between PC2 & PC3 (which, in the end will be more than 1 PC). So if the user clicks on the dropdown on the VISA resources control, it will provide all of the resources found, but doesn't tell the user which PC is the resource from.
That's why I'm trying to find a way to differentiate the serial ports on PC2 & PC3.
Thanks for the help
08-12-2014 11:33 AM
Hi crossrulz,
Thank you for the suggestion. The only problem is that I would have to do that for every single PC3 (see diagram) that I connect to my "network".
Thanks.
08-12-2014 12:00 PM
I would start to consider alternate means to communicate PC's rather than using remote VISA calls. Consider using TCP/IP calls between the machines and let the computer that is strictly serving up the serial ports run a small VI daemon to provide an interface between calls it gets via TCP/IP and the serial ports.
I really don't understand why you feel it is such a problem to change the VISA alias on all the PC's, whether it is 3 or 20. You are creating a system of communication. You pretty much have to touch each PC to get it set up and connected to your network and get the VISA drivers installed. How much more difficult is it to take the time and rename the VISA alias on that PC?
I've only played with a remote VISA serial port one time, so I don't remember all the details. But if I'm not mistaken, can't you see and configure that remote port from within MAX on your PC?
08-12-2014 12:31 PM
Hey RavensFan,
My first thought was to configure the remote port through MAX. However, I had the problem of my remote system not showing up on MAX even with the server started on all of the PCs. The NI-VISA Interactive Control can find it, but NI-MAX could not.
Also, I'm not very familiar with TCP/IP calls. Is there a simple VI tutorial that I could use?
Thanks.
08-12-2014 12:36 PM
@jachy25 wrote:
Also, I'm not very familiar with TCP/IP calls. Is there a simple VI tutorial that I could use?
Look in the LabVIEW Example Finder (Help->Find Examples). There's a set of Client and Server VIs that you can use as reference. I would also recommend giving a good look at the STM library.