LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to accelerate the sampling rate in the WIFI communication from myRIO to PC with shared variables?

Dear experts,

 

I am recently setting a mobile data transfer system, using WIFI communication of myRio.

 

Once setting the wifi environment of myrio, I have been following the easy protocol, declaring the shared variables at myRio, and read it from Host PC.

 

Since I do not use any other wifi router, and just create wifi from myrio and connect the PC to that configuration, it seems that the speed is not satisfactory for the target application (10Hz).

 

If there are some ways or tips to solve the issues of slow acquisitions, I would like to ask for your valuable advice.

 

Thank you in advance for your attention and considerations.

 

Best regards, 

 

0 Kudos
Message 1 of 4
(1,390 Views)

Attach (all of) the LabVIEW code that you are using so we can understand what you are trying to do.  If you are trying to send data one sample at a time using Shared Variables, you should certainly be able to do 10 Hz.  TCP/IP should be able to transfer data much faster, at least 20-50 kHz without too much effort (I haven't really pushed it).

 

Bob Schor

0 Kudos
Message 2 of 4
(1,351 Views)

Dear Bob Schor,

 

Thank you so much for your attention. I attached a zip file of the LabVIEW project.

 

I would respectfully request you to look for this Labview code. Myrio reads the sensor data using FPGA, and sends the data to the host PC using shared variables.

 

If there are the ways to accelerate the wireless data communication, it would be a really big help for our applications.

 

Best regards, 

 

0 Kudos
Message 3 of 4
(1,346 Views)

Thank you for attaching your code, which I was able to open successfully.  However, trying to figure out what you are trying to do is, for me, quite difficult.  It is, of course, complicated by the fact that there are three independent processes -- code running on the FPGA (doing "something" at "some rate"), code running on the myRIO (I'll call this "Target") interacting somehow with the FPGA using a Handshake, and code running on the PC (I'll call this "Host") talking to the Target using a Shared Variable.

 

Mixed in among all of this is some hardware involving a 6-bit DIO register doing something, a two-channel A/D input and a two-channel D/A output, all running at some unknown clock speed (not sure where this is being set, but it could go as fast as 10 FPGA ticks up and down, or 40/20 (= 2) MHz, pretty fast.

 

Suggestion -- if your question is how to get data (I'm not even sure what/how much data you are trying to send) from the Target to the Host, write a very simple VI that generates "Sensor Output" at some known rate.  Make the output simple -- an array of [1,1,1,1], [2,2,2,2], [3,3,3,3], etc., something you can recognize and watch.  Clock it however you want, and try to send it to the Host.

 

I've long given up on Network Shared Variables, so I don't have advice to give you there, except to study the Examples that (I hope) ship with LabVIEW.  Start with a known, slow, transfer rate, maybe a few Hz (like 1), just to see that you get numbers sent from Target to Host.

 

Just out of curiosity, can you describe the data that you are trying to send in "Sensor Output"?  I see it's an I16 array, but I'm uncertain of the size, and the expected contents.  It is not so easy to deduce by just looking at your code ...

 

Bob Schor

0 Kudos
Message 4 of 4
(1,332 Views)