LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I run a model through two different networks?

My boss has asked me to try and figure out if it's possible to connect models on two different networks.  We've run tests using both TCP and Shared Variables were we've just sent over simple Boolean, integer, and array data types over a network.  One test where we've connected to each other using a Gigabit switch and we're right next to each other.  Another test over a LAN connection but at a much farther distance (few rooms apart).  But now, my boss wants to see if it's possible for me to do this at an even greater distance (i.e. from my house).  Is this even possible?  If so, using what transfer protocol?  It's real time data we're looking to send across so ftp wouldn't work (I think).  We've been exploring data socket protocol and we've gotten it to work, but only when we're connected through the same LAN connection.  If someone could point me in the right direction as to where we should be looking for possibly doing something like this, I'd greatly appreciate it.  If this is not possible, please also explain why.  *Using LabVIEW 8.5.
 
Regards
Chris Allen
Associate Research Engineer
Modeling and Simulation Analysis Team
WPAFB
0 Kudos
Message 1 of 4
(3,229 Views)
Hi Chris,
 
This is definitely possible to do. However, the network is not deterministic. However, you can do this using both TCP or network shared variables. My first suggestion would be to use shared variables since you can buffer the data by using a Real-Time FIFO. TCP will probably be quicker but it offers no buffering.
 
Also, it might help to know more information about your application. What are you trying to do? What type of data are you transferring and what type of acquistion do you have? I hope this helps a bit!
 
 
 
Carla
National Instruments
Applications Engineer
0 Kudos
Message 2 of 4
(3,194 Views)
As of right now the data types to be transferred are really up to us.  Our goal is to demo this capability to others and get some brainstorming going for future projects involving the same process.  So currently, we're looking to just show it's possible to perform data transfer across long distances. 
 
Our previous tests using LAN connections involved sending over a small amount of variables of different data types and measuring the time delay between data transfer.  Attached is a simple TCP vi I helped set up that we used across our LAN we have here in the labs.  How can we do this same type of test when the server is in one location (i.e. the lab) and the client is farther away (i.e. my home)?
Download All
0 Kudos
Message 3 of 4
(3,180 Views)

Hi MSAT,

Using TCP/IP to transfer data is definitely an option to use when you have the server in one location and the client in a far away location. This type of protocol enables communication over single networks or interconnected networks. These individual networks can be separated by large geographical distances. Another method that could work as well is DataSocket. With this method, you can pass data over the Internet and respond to multiple users.  There are several examples that are a great starting point in the NI Example Finder. One great example to look at is DS Writer.vi and DS Reader.vi (under the Browse tab, double-click Networking»DataSocket»General ). This should be able to work fine from one location to the other. One thing to check is the DataSocket Security and make sure you do not have any firewalls blocking the data transfer. Also, make sure that you use the DataSocket Server Manager to configure the correct permission settings so that your remote machine has permission to create and write items on the DataSocket Server. There is a document in the NI Developer Zone entitled "Configuring a Datasocket Server" that should get you started in the right direction. There are also several Datasocket examples in the Developer Zone that demonstrate how to use Datasocket functionality within your LabVIEW program.  I hope this helps get you started!

 

Carla

National Instruments
Applications Engineer
0 Kudos
Message 4 of 4
(3,164 Views)