Actor Framework Documents

cancel
Showing results for 
Search instead for 
Did you mean: 

Advanced Message Maker

This is a package for LabVIEW's Actor framework to help message creation.

How to install?

Update:

install the dependencies in this order:

"dr_langer_medical_lib_vipm_support-1.0.0.4.vip"

"AMM_dependencies.vipc"

Run the "dr_langer_medical_lib_af_advanced_message_maker-1.0.2.12.vip" using VIPM.

what has changed: Intellingent wiring. Previously only terminals of the same data-type with matching names were connected. Now wiring is done also with similar names and matching data-type (of course). (Levenshtein-Distance)

Just run the "dr_langer_medical_lib_af_advanced_message_maker-1.0.1.9.vip" using VIPM.

Just run the "dr_langer_medical_lib_af_advanced_message_maker-1.0.0.8.vip" using VIPM.


It will install this add-on and all it's dependencies.

You will have to install "dr_langer_medical_lib_extor_addon-1.0.0.8.vip" also to have the most up to date Extor installation (it has some more palette elements)

All the packages that I used will be installed by the VIPM. Please read all the licence agreements. These are mostly BSD, FreeBSD of 3-clause BSD.

I couldn't find the VI package for a component that I use so I had to integrate it in my source code but I would like to mention it here. So I used Ton Plom's Variant to Control which is shared under BSD(Most Common) license. You can read more on it here.

Update:

At the first run it will ask for a "temporary controls" and a "temporary indicators" folder. Choose two folders that you have read/write rights to and these two folders should be different! Important: if the folders are chosen to be the same the message making will not function correctly!

In case you didn't select the folders you wanted, you can always change it later in the Settings.

Updating LabVIEW?

Before update, uninstall the "dr_langer_medical_lib_newaccessors_extension-1.0.0.6.vip" (it will uninstall the advanced message maker also, because it's a dependency of the advanced message maker)

After update reinstall the "dr_langer_medical_lib_newaccessors_extension-1.0.0.6.vip" and the "dr_langer_medical_lib_af_advanced_message_maker-1.0.2.12.vip".

Explanation: There is one component in the dependencies that adds a VI to a LabVIEW library in the LabVIEW installation folder. This VI makes the (otherwise protected) "property access VI" creation public. This way I can use it programmatically to create property access VIs for the Message Injection info stored in the Actor's Class's private data control.

I have tested this component for install - uninstall, and that worked fine. But upon a LabVIEW update my modification the lvlib gets "corrected".

How to use?

With the current version you can make 3 types of messages:

  • Receive Message

    •   This message is the "normal" message.  It is an input to an Actor.
  • Send Message

    •   This message creates an output from an Actor. This contains 2 receive messages.
      • MessageInjection: this is used upon initialization. This message tells the Actor that who is the listener to the Send message.

      •   Abstract Message: this is a receive message but with no content. It only serves as a placeholder and will be overridden by dynamic dispatch if the MessageInjection was successful.
  • Transmit message

    • This message creates a connection between the Send and the Receive message. It is the child of the Send's Abstract message, and has the same name for the Send method to make dynamic dispatching possible.

What is an Extor?

As you may noticed I use a new parent for the actors. This is called Extor and should mean extended actor. It is a child class of the Actor class and extends it with fast identification capabilities. You have to use a new "Launch Extor.vi" to launch it which is installed with the VI package. It is basically the same as "Launch Actor" but you have to select upon launch the identification method by connecting an "Identify By" class to it. That's also found on the new palettes (medical-langer/Extor AddOn/Identify By). I have created two identification types, one is by Enqueuer, the other is by Clone Number of the Actor Core. I use the "by Clone No." that is really fast.

So after launching it, the extor receives it's ID and stores it in the Extor object's private data. It is also returned from the "Launch Extor.vi" so you can use it to create the mapping in the actor that will transmit the messages. There are some new classes for storing the mapping and looking it up runtime. Just check out the example project to see how to use it. With every Send message the Actor ID is also sent, and the transmitter extor uses this ID for routing the message to the right extor's Receive message.

If you plan to use it on Actor based projects, you have to change your actors to inherit from Extor and replace the "Launch Actor.vi" to "Launch Extor.vi". That's all (I hope, please send feedback if you have done it successfully) and you are ready to use the new message types.

Update:

I have recorded some youtube videos to introduce the Advanced Message Maker.


Explaining the example project:

Advanced Message Maker - 01 - Example project1

Advanced Message Maker - 02 - Example project2

Advanced Message Maker - 03 - Example project3

Advanced Message Maker - 04 - Settings

Advanced Message Maker - 05 - How to use

And a VERY IMPORTANT thing: I discovered a very nasty LabVIEW bug and couldn't find a workaround. It is reported to NI and I wait for the solution, but until that is fixed be aware that LabVIEW may crash on you if you attempt to make 2 or more send messages without closing and reopening Advanced Message Maker, or even after creating one Send message and attempting to close Advanced Message Maker.

Update: The bug is probably solved! We could find a workaround to stop it from happening.


So now both connector panes are OK to work with:

4x4cp.png

So this is Ok.

5x5cp.png

And this is Ok.

And the NI support told me that they tested the workaround (with success) for many other differently connected connector panes.


This is an experimental release, the GUI is not the best, more types of messages could be created, tree would be better than list control, but at least you can try it now. So

please share your suggestion with me about what you would like to see, what are you impressions, etc.

I also share the example project that I show in the videos.

(Update: The example project is also updated. Some new read and write methods were created for both AaA and BbB actors. I used these for testing the message creation)

I open a discussion about this Advanced Message Maker, if you have anything to say about it, please post it there.

Comments
3esmit
Member
Member
on

Great Tool, but I am sad I have to use Extor class in hierachy. Is not possible to make it without this class, just directly in Actor?

komorbela
Member
Member
on

I will take a look at it. I hope it's not complicated   Will let you know soon!

Contributors