<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Change UDP Socket.ReceiveBufferSize under Windows in LabVIEW</title>
    <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499502#M238564</link>
    <description>&lt;DIV&gt;&lt;/DIV&gt;This is very usefull for my application.&amp;nbsp; Does anyone have something that will work in 7.1.&amp;nbsp;</description>
    <pubDate>Thu, 29 Mar 2007 15:39:59 GMT</pubDate>
    <dc:creator>Draper_Lab</dc:creator>
    <dc:date>2007-03-29T15:39:59Z</dc:date>
    <item>
      <title>Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/483098#M232025</link>
      <description>I've previously used a LabVIEW LLB that allows customizing a &lt;I&gt;TCP socket&lt;/I&gt; &lt;A href="http://digital.ni.com/public.nsf/allkb/7EFCA5D83B59DFDC86256D60007F5839" target="_blank"&gt;(TCP_NODELAY LLB&lt;/A&gt;) to enable and disable delayed acks. This NI LLB contains a pasword protected VI that returns a raw TCP socket ID that is in turn used as an input to a Call Library Function node. &lt;A href="http://forums.ni.com/ni/board/message?board.id=170&amp;amp;message.id=103952&amp;amp;requireLogin=False" target="_blank"&gt;A previous post on the NI forums indicates to me that the Windows default buffer size is used (8192 bytes).&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;I would like to increase the Socket.ReceiveBufferSize for a LabVIEW UDP Connection ID.&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://msdn2.microsoft.com/en-us/library/system.net.sockets.socket.receivebuffersize.aspx" target="_blank"&gt;MSDN Windows Socket.ReceiveBufferSize property info&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 26 Feb 2007 14:37:56 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/483098#M232025</guid>
      <dc:creator>PhillipBrooks</dc:creator>
      <dc:date>2007-02-26T14:37:56Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/484166#M232495</link>
      <description>&lt;DIV&gt;Hi Phillip,&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;So are you calling a DLL like the LLB does, or are you using the built in UDP VIs from LabVIEW.&amp;nbsp; If you are using the built-in VIs then the operating system and LabVIEW implement buffers that the user cannot configure.&amp;nbsp; If you are using a DLL call, then which one is it in particular.&amp;nbsp; Thanks for the extra information.&lt;/DIV&gt;</description>
      <pubDate>Wed, 28 Feb 2007 00:52:22 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/484166#M232495</guid>
      <dc:creator>Brian_K.</dc:creator>
      <dc:date>2007-02-28T00:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/484447#M232596</link>
      <description>&lt;DIV&gt;&lt;/DIV&gt;Sorry for the confusing post. I'm using the LabVIEW UDP VIs. My situation is:&lt;BR /&gt;
&lt;BR /&gt;
I am running three UDP receivers (Reentrant VI &amp;amp; VI Server) using
three point-to-point Gigabit Ethernet connections. I drop data when
sending rates are &amp;gt; 2.4 Mbit/sec. Data is only sent in one
direction. I have used a TCP version of my application where the CPU
load is ~ 50%, with (of course) no dropped data because of TCP. I have
also used &lt;A href="http://digital.ni.com/public.nsf/allkb/7EFCA5D83B59DFDC86256D60007F5839" target="_blank"&gt;TCP_Nodelay.llb&lt;/A&gt; to disable nagling, and see 80 to 90% CPU utilization. &lt;BR /&gt;
&lt;BR /&gt;
I've simply replaced the TCP Open, Receive and Close functions with UDP
functions. While running, my CPU load fluctuates from 80 to 100%, and I
drop data.&amp;nbsp; UDP has no sequencing or acks to manage, so I can't imagine
why the CPU load would be higher AND that I would drop data. I've run
the UDP version at half my goal (1.2 MBit/sec) without dropping data. I
do use a 1 ms timeout on the UDP and TCP reads.&lt;BR /&gt;
&lt;BR /&gt;
I would like to use the same technique to retrieve a &lt;B&gt;UDP raw socket ID&lt;/B&gt;, then use that ID to configure &lt;B&gt;SO_RCVBUF&lt;/B&gt; instead of &lt;B&gt;TCP_NODELAY&lt;/B&gt; to try and eliminate the data loss. I would like to increase the buffer size, or even possibly set it to zero &lt;A href="http://www.codeguru.com/forum/showthread.php?t=229577" target="_blank"&gt;after reading this CodeGuru forum entry.&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;IMG src="http://forums.ni.com/attachments/ni/170/232596/1/TCP_NODELAY.llb.gif" /&gt;&lt;BR /&gt;
&lt;BR /&gt;
&lt;DIV&gt;&lt;/DIV&gt;&lt;P&gt;Message Edited by Phillip Brooks on &lt;SPAN class="date_text"&gt;02-28-2007&lt;/SPAN&gt; &lt;SPAN class="time_text"&gt;10:13 AM&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Feb 2007 15:12:44 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/484447#M232596</guid>
      <dc:creator>PhillipBrooks</dc:creator>
      <dc:date>2007-02-28T15:12:44Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/485378#M232969</link>
      <description>&lt;DIV&gt;&lt;/DIV&gt;
&lt;P&gt;HI Phillip,&lt;/P&gt;
&lt;P&gt;So I am still not 100% sure what we are trying to do, but I did find something.&amp;nbsp; In the [LabVIEW X.X]\vi.lib\Utility\tcp.llb there is a VI called UDP Get Raw Net Object.vi.&amp;nbsp; I think it is the equivalent to the TCP version you were talking about.&amp;nbsp; Tell me if I am on to something.&lt;/P&gt;</description>
      <pubDate>Thu, 01 Mar 2007 21:42:09 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/485378#M232969</guid>
      <dc:creator>Brian_K.</dc:creator>
      <dc:date>2007-03-01T21:42:09Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/487348#M233749</link>
      <description>&lt;DIV&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;/DIV&gt;
&lt;P&gt;That was the piece of information that I needed. I am now able to increase the buffer size for a UDP socket (from default of 8192 bytes), and my data loss problems have gone away for now.&lt;/P&gt;
&lt;P&gt;I'll share my simple VI (LV 8.0) for those who may be interested in the future...&lt;/P&gt;
&lt;P&gt;&lt;IMG src="http://forums.ni.com/attachments/ni/170/233749/2/UDP%20SO_RCVBUF.gif" /&gt;&lt;/P&gt;
&lt;P&gt;Message Edited by Phillip Brooks on &lt;SPAN class="date_text"&gt;03-06-2007&lt;/SPAN&gt; &lt;SPAN class="time_text"&gt;12:39 PM&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Message Edited by Phillip Brooks on &lt;SPAN class="date_text"&gt;03-06-2007&lt;/SPAN&gt; &lt;SPAN class="time_text"&gt;12:40 PM&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 06 Mar 2007 17:38:58 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/487348#M233749</guid>
      <dc:creator>PhillipBrooks</dc:creator>
      <dc:date>2007-03-06T17:38:58Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499502#M238564</link>
      <description>&lt;DIV&gt;&lt;/DIV&gt;This is very usefull for my application.&amp;nbsp; Does anyone have something that will work in 7.1.&amp;nbsp;</description>
      <pubDate>Thu, 29 Mar 2007 15:39:59 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499502#M238564</guid>
      <dc:creator>Draper_Lab</dc:creator>
      <dc:date>2007-03-29T15:39:59Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499572#M238607</link>
      <description>I've saved and attached the file in 7.1 format. I do not have 7.1 on a computer where I can easily test it though. Note that the DLL call is to wsock32.dll.&lt;BR /&gt;&lt;BR /&gt;If you are using LabVIEW for Linux, you may need to modify the DLL call...&lt;BR /&gt;&lt;BR /&gt;Phillip Brooks&lt;BR /&gt;Dynamics Research Corp - ETO&lt;BR /&gt;West Newton, MA&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 29 Mar 2007 17:24:30 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499572#M238607</guid>
      <dc:creator>PhillipBrooks</dc:creator>
      <dc:date>2007-03-29T17:24:30Z</dc:date>
    </item>
    <item>
      <title>Re: Change UDP Socket.ReceiveBufferSize under Windows</title>
      <link>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499582#M238613</link>
      <description>&lt;DIV&gt;&lt;/DIV&gt;Thanks Phil, Where you work at DRC we may be using this for the same application.</description>
      <pubDate>Thu, 29 Mar 2007 17:37:55 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/Change-UDP-Socket-ReceiveBufferSize-under-Windows/m-p/499582#M238613</guid>
      <dc:creator>Draper_Lab</dc:creator>
      <dc:date>2007-03-29T17:37:55Z</dc:date>
    </item>
  </channel>
</rss>

