Jump to content

Open VI with connector pane


JDave

Recommended Posts

I found a few threads (like this) that talk about calling plugin VIs. I thought that the connector pane would be an easy way to verify that the plugin is valid.

Having played with the LV 8+ replacement for the Icon Editor a bit, I noticed that they require a certain connector pane in order for your replacement VI to be valid. Here is the interesting thing, though. They allow you to connect terminals that are unconnected in their template connector pane.

But then it would seem that using the Call By Reference Node would be unavailable because it requires a strictly typed VI with an exact match on the connector pane.

Does anyone know of a way to check if a VI matches a template connector pane, that ignores unconnected terminals in the template? The plugin may or may not use these terminals and it should not matter. Can I mimic what the Icon Editor does, or is this just not feasible?

David

Link to comment

QUOTE(dsaunders @ Sep 11 2007, 01:09 PM)

Does anyone know of a way to check if a VI matches a template connector pane, that ignores unconnected terminals in the template?

I'm not in front of my dev box right now, but there is a private property node that gives the ConPane resid for a VI. So yes, it is possible.

Here is a list of resid's for conpanes that I had here on my USB stick (you could just compare the template's with the VI in question, but here is a list anyway):

1 48003 48034 48061x1 48012x1 48022x2 48052x1x1 48303x1 48043x2 48073x1x1 48313x1x2 48323x3 48104x1 48084x2 48094x3 48114x4 4812[2.5x2.5]x1 48164x1x1 48234x1x2 4824[2.5x2.5]x2 4817[2.5x2.5]x3 48184x1x3 4825[2.5x2.5]x4 48194x1x4 4813[2.5x2.5]x[2.5x2.5] 48204x1x1x4 4826[2.5x2.5]x2x4 48214x2x1 48274x2x2 48284x2x3 48224x2x4 48144x2x1x4 48294x2x2x4 48155x2x2x2x5 48336x2x2x2x2x6 48348x2x2x2x2x2x2x8 4835Weird 4836

Link to comment

QUOTE(dsaunders @ Sep 11 2007, 03:09 PM)

I found a few threads (http://forums.lavag.org/Calling-a-VI-using-VI-Server-The-VI-is-not-in-a-state-compatible-with-this-operation-t2772.html&view=findpost&p=9908' target="_blank">like this) that talk about calling plugin VIs. I thought that the connector pane would be an easy way to verify that the plugin is valid.

Having played with the LV 8+ replacement for the Icon Editor a bit, I noticed that they require a certain connector pane in order for your replacement VI to be valid. Here is the interesting thing, though. They allow you to connect terminals that are unconnected in their template connector pane.

But then it would seem that using the Call By Reference Node would be unavailable because it requires a strictly typed VI with an exact match on the connector pane.

Does anyone know of a way to check if a VI matches a template connector pane, that ignores unconnected terminals in the template? The plugin may or may not use these terminals and it should not matter. Can I mimic what the Icon Editor does, or is this just not feasible?

The private property is somewhat a pain to use as it is really a number of informations you would need to check. First the connecter pane layout itself which is just a magic number for one of the patterns you can choose. Then the array of connections with an arbitrary number to identify the position in the connector pane it is connected too and last but not least the datatype of each connection which is a binary type descriptor and can't just be compared byte for byte but needs to be verfied on a logical level since different binary representation do not necessarily mean different data types.

Not sure I would want to spend that much time for this!

Another possibility and LabVIEW uses that a lot for its plugins is to use the Set Control Value method and then simply run the plugin VI. Makes the connector pane completely independant of the calling information. You just need the correctly named controls on the front panel. Using an occurrence (or notifier etc.) you can wait in the caller for the VI to signal its termination or simply poll its status to be not running anymore.

Rolf Kalbermatter

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
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.