How to increase UDP data rate for transfering data from simulink to visual studio?

1 view (last 30 days)
<<
>>
I want to develop an application in which data received through USRP board is processed using Simulink and the processed data is then passed to Visual Studio in a real-time fahsion using UDP, and then visual studio displays/renders the data. (the visual studio application for rendering the data has already been developed and used extensively so I want to re-use that code in this application)
Question # 1: Is the 'real-time thing' possible?
Before using the actual hardware I wanted to test the interface between simulink and visual studio so I developed a test model and a test visual studio application. I just read a file in simulink and send that data to 'UDP send block'(from instrument control toolbox) and receive the same using visual studio. I was able to succesfully stream the data in visual studio. But there is a drastic difference in the rate at which data is given to the udp block and the rate at which data is received in visual studio. For instance, data is given to 'UDP send' block at a sample time of '1/1000000000' with 200bytes/unit-time and data is received in visual studio at a rate of 1.189Mbps. (Simulink model image attached, Figure 1)
Question # 2: Why is this difference in rates?
Question # 3: How can rate at which data is received in visual studio can be increased?(other than further reducing the sampling time in simulink block?
I added a few processing block in the test model (as shown in Figure 2) which further reduced the the rate at which data is being received in visual studio. It was because sampling time needed to be increased for this model. However, the rate at which 'FSK demod' block is receiving the data is much higher than it will be whne the actual hardware will be used.
Question #4: Will this receiving rate further drop down or simulink model will behave in a real time fashion when actual USRP hardware is conneceted?
If I am missing something or doing some mistake in the overall system, please mark out!
Thanks
Shaji

Answers (0)

Categories

Find more on Communications Toolbox in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!