<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://msmvps.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx</link><description>Problems exist to be solved. Some problems are so complex that you cannot solve them when you need to. With other problems it is not a matter of complexity, but a matter of not having all the pieces of the puzzle. Some problems are so interesting that</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#1658747</link><pubDate>Wed, 07 Jan 2009 12:58:54 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1658747</guid><dc:creator>vn</dc:creator><description>&lt;p&gt; i need to pass the below structure from labVIEW to C DLL Can you help me out in this....is there an option to pass without writting a wrapper?or could how could you pass these kinda structures in labVIEW. &lt;/p&gt;
&lt;p&gt;typedef struct &lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt;unsigned long NumOfParams;&lt;/p&gt;
&lt;p&gt;SCONFIG *ConfigPtr;&lt;/p&gt;
&lt;p&gt;} SCONFIG_LIST&lt;/p&gt;
&lt;p&gt;typedef struct&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt;unsigned long Parameter;&lt;/p&gt;
&lt;p&gt;unsigned long Value;&lt;/p&gt;
&lt;p&gt;} SCONFIG &lt;/p&gt;
&lt;p&gt;kindly help me &lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1658747" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#1658745</link><pubDate>Wed, 07 Jan 2009 12:47:36 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1658745</guid><dc:creator>vn</dc:creator><description>&lt;p&gt; i need to pass the below structure from labVIEW to C DLL Can any one help me out .....is thr an option to pass without writting a wrapper?PL do help .....&lt;/p&gt;
&lt;p&gt;typedef struct &lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt;unsigned long NumOfParams;&lt;/p&gt;
&lt;p&gt;SCONFIG *ConfigPtr;&lt;/p&gt;
&lt;p&gt;} SCONFIG_LIST&lt;/p&gt;
&lt;p&gt;typedef struct&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt;unsigned long Parameter;&lt;/p&gt;
&lt;p&gt;unsigned long Value;&lt;/p&gt;
&lt;p&gt;} SCONFIG &lt;/p&gt;
&lt;p&gt;pl do help me....&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1658745" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#1645344</link><pubDate>Thu, 21 Aug 2008 09:04:20 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1645344</guid><dc:creator>Martin Boecskoer</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;i am trying to implement a hardware in labview for my master thesis (sports science). as i am no programmer i am having not enough knowledge to get the things working right. &lt;/p&gt;
&lt;p&gt;the problem i have got is simmilar to the one you solved.&lt;/p&gt;
&lt;p&gt;i need to suply a function with a pointer to a callback function defined as&lt;/p&gt;
&lt;p&gt;typedef BOOL (_stdcall *CHANNEL_EVENT_FUNC)(UCHAR ucANTChannel, UCHAR ucEvent);&lt;/p&gt;
&lt;p&gt;it is used in&lt;/p&gt;
&lt;p&gt;_declspec(dllexport) void ANT_AssignChannelEventFunction(UCHAR ucANTChannel, // Initialize Channel pointers&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;CHANNEL_EVENT_FUNC pfChannelEvent,&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;UCHAR *pucRxBuffer);&lt;/p&gt;
&lt;p&gt;used in the c file as following&lt;/p&gt;
&lt;p&gt;__declspec (dllexport) void ANT_AssignChannelEventFunction(UCHAR ucLink, CHANNEL_EVENT_FUNC pfLinkEvent, UCHAR *pucRxBuffer)&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; sLink[ucLink].pfLinkEvent = pfLinkEvent;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; sLink[ucLink].pucRxBuffer = pucRxBuffer;&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;if you could help me by solving the problem i would be very thankfull or if you could make things work. i would pay for it too.&lt;/p&gt;
&lt;p&gt;thank you a lot&lt;/p&gt;
&lt;p&gt;martin&lt;/p&gt;
&lt;p&gt;(email martin.boecskoer(at)aon.at)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1645344" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#1634978</link><pubDate>Sat, 14 Jun 2008 12:43:08 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:1634978</guid><dc:creator>tomsun</dc:creator><description>&lt;p&gt;I&amp;#39;m new in .net, I have the similar problem, I need your help.&lt;/p&gt;
&lt;p&gt;The following is the prototype of the callback function:&lt;/p&gt;
&lt;p&gt;VOID(_stdcall *VideoFilter)(VOID *pcontext, BYTE *pData,ULONG dataLength)&lt;/p&gt;
&lt;p&gt;Can you give me the corresponding .NET code?&lt;/p&gt;
&lt;p&gt;Thank you in advance.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=1634978" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#704046</link><pubDate>Fri, 23 Mar 2007 17:29:23 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:704046</guid><dc:creator>Rexxar</dc:creator><description>&lt;p&gt;Sorry for lose link.&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://forums.ni.com/ni/board/message?board.id=170&amp;amp;message.id=237441"&gt;http://forums.ni.com/ni/board/message?board.id=170&amp;amp;message.id=237441&lt;/a&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=704046" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#704045</link><pubDate>Fri, 23 Mar 2007 17:28:30 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:704045</guid><dc:creator>Rexxar</dc:creator><description>&lt;p&gt;Hi &lt;/p&gt;
&lt;p&gt;Thanks very much for this link, but I have a question when the callback function is a VI code and the caller is a dll function. Could you please read this post and give me a reply to&amp;quot;paulbin@126.com&amp;quot;?&lt;/p&gt;
&lt;p&gt;Thanks very much again.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=704045" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#566639</link><pubDate>Sun, 11 Feb 2007 17:20:51 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:566639</guid><dc:creator>silver</dc:creator><description>&lt;p&gt;Hi Joe&lt;/p&gt;
&lt;p&gt;I have the same problem that you had.&lt;/p&gt;
&lt;p&gt;Can you tell me how can I update LabVIEW&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=566639" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#534274</link><pubDate>Thu, 01 Feb 2007 15:33:08 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:534274</guid><dc:creator>George Puiklis</dc:creator><description>&lt;p&gt;Hello Joe,&lt;/p&gt;
&lt;p&gt;How did you update labview? I mean 8.2 is the latest version. I am getting the same error you did (for another vi though).&lt;/p&gt;
&lt;p&gt;George&lt;/p&gt;
&lt;p&gt;(mail: gpouikli at ee.duth.gr)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=534274" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#508388</link><pubDate>Sun, 21 Jan 2007 07:53:38 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:508388</guid><dc:creator>Joe Ziegler</dc:creator><description>&lt;p&gt;Updated Labview and it worked flawless. &amp;nbsp;This is awesome. &lt;/p&gt;
&lt;p&gt;Thanks, Joe&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=508388" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#504072</link><pubDate>Fri, 19 Jan 2007 05:31:16 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:504072</guid><dc:creator>Joe Ziegler</dc:creator><description>&lt;p&gt;I am getting the error...&lt;/p&gt;
&lt;p&gt;VI version is later than the current LabVIEW version. &amp;nbsp;An error occurred loading VI 'CleanupCallback.vi'. &amp;nbsp;LabVIEW load error code 9: VI version (8.2) is newer than the LabVIEW version (8.2b23).&lt;/p&gt;
&lt;p&gt;Strange....its basically the same version. &amp;nbsp;Just off by a little b23. &amp;nbsp;You would think a newer version would be somewhat backwards compatable. Guess not. &amp;nbsp;So, how can I find out what is in &amp;quot;get callback function pointer&amp;quot; and cleanup callback? &amp;nbsp;Great article..can't wait to impliement it. &lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=504072" width="1" height="1"&gt;</description></item><item><title>re: Executing LabVIEW VIs through C style function pointers via .NET</title><link>http://msmvps.com/blogs/vandooren/archive/2006/11/16/executing-labview-vis-through-c-style-function-pointers-via-net.aspx#414183</link><pubDate>Tue, 12 Dec 2006 08:46:14 GMT</pubDate><guid isPermaLink="false">d67277c4-116b-43f1-b688-e9ef184ea916:414183</guid><dc:creator>Damjan</dc:creator><description>&lt;p&gt;Hello!&lt;/p&gt;
&lt;p&gt; Your solution is usefull also to solve an old problem here in my lab. &amp;nbsp;I'm new in C#. I have a problem with your sourcecode. &amp;nbsp;My compiler (Borland Dev.Studio) can't load the:&lt;/p&gt;
&lt;p&gt;using System.Collections.Generic; &lt;/p&gt;
&lt;p&gt;Any ideas?&lt;/p&gt;
&lt;p&gt; &amp;nbsp;regards, Damjan&lt;/p&gt;
&lt;p&gt;KRIZMANCIC at TASC dot INFM dot it &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msmvps.com/aggbug.aspx?PostID=414183" width="1" height="1"&gt;</description></item></channel></rss>