Jump to content

How to Implement Callback function using LabVIEW


Recommended Posts

The IEC61850_Associate_Req function has a callback fuction Confirmation as one of its parameters. How do I implement the callback using the Call Library Function node

int_stdcall Confirmation(LPCTSTR Msg)

{

printf("\n***Confirmation (callback)***\n%s\n", Msg);

return 0;

}

result= IEC61850_Associate_Req(request.c_str(), Confirmation, response, 1024);

if(result)

{

return result;

}

In the above program, request and response is an xml based strings.

I am stuck in this logic for past one week.

Link to comment

Hi vugie,

Thanks for your help..

As I am new to LabVIEW and C, I am not able to proceed with the details given.

Can you please provide a simple logic based on the inputs given by me to continue further.

Thanks,

You will need to learn some C AND LabVIEW for sure. The example in the link from vugie provides all that is necessary with only one difference and that is the prototype of your function itself. If your knowledge is so limited that this is to much to do yourself you will run into many more trouble along the way and should consider to either try to find a non callback solution or hire someone who does this part for you.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.