03-17-2016 02:40 PM
A book is a good idea... If you want a collaborator, let me know!
03-17-2016 03:11 PM
I just had a look at the two AF sample projects in LabVIEW 2015, "Actor Framework" and "Feedback Evaporative Cooler". They could do with improvement to help promote the AF to new Users. With neither project was it easily possible to open the block diagram of the main running actor. I had to modify both main actors to allow the BD to be openned. With "Actor Framework" I had to modify the Run-time menu to allow "Open block diagram, then I set the inputs on the launch of Actors A and B to show front panel. Easy if you know, but a new person would not know this. I was pleasently surprised to find I could click on Actor.lvlib:Actor Core and get the right clone (how long has that worked?), and so I could probe the Actor object inside its message-handling loop. Though I had to make a custom probe to get useful info, as in the Actor message-handling loop is a parent-class wire. I then went after the messages, opening a "Do" method and selecting 'View>>Browse Relationships>>Reentrant Items' to get to the running clones. Could have used a breakpoint, too. Didn't need a custom probe here, but then, in the Do methods I may be probing multiple actors, and I'm not probing every message to an actor, so this is not at all an ideal location to probe actor state.
This isn't "Debugging 101". Simple LabVIEW programs (LVOOP included) are double-click-to-open, ctrl-E, click-on-wire. Very easy, very quick. Debugging shared-reentrant clones requires additional knowledge that a lot of developers may not have when first trying the Actor Framework. I recently introduced non-reentrant actors to my "Messenger Library"; I don't need them myself, but they an easier route in for a new person.
03-17-2016 03:50 PM
No, it is obviously not "Debugging 101", but it doesn't require a CS degree to debug. It's at the level of debugging re-entrant code -- something I learned 15 or 20 years ago when I was new to LV. It's something that beginners aren't expected to know (as with many aspects of LV), but they shouldn't ignore or gloss over it either.
I have never found it useful to probe 'Actor.lvclass:Actor Core.vi'. My main running actors have several block diagrams; they have several methods, and probing within the methods has proven more useful for me. (And, as mentioned above, a simple override to 'Receive Message.vi' for an actor will provide the actor's PDC wire for probing every message/reaction without having to resort to opening the innards of the AF. But I still find it more effective to probe within specific actor methods.)
I have never had to modify actors in any unusual way in order for their methods' block diagrams to open so that I could probe. This includes the block diagrams of Actor Core overrides (which I find rarely requires probing anyway). For those actors which I implement an Actor Core override, their FP opens when they're launched -- the purpose of the override is to present a GUI, in nearly every case. (If I need a "helper loop" for an actor, I prefer to delegate to a second actor, not the Actor Core override.)
It's still not complicated, even with re-entrancy: double-click to open, Ctrl-E, set a breakpoint, run the actor, wait for the BD to open (in a clone, but it's still a BD), probe wires. Very easy, very quick.
03-18-2016 03:56 AM
Use "Open Actor Core front panel?" and then when the VI opens, you can double click on the call to the parent implementation to open that clone, and so on, all the way to the actual clone of Actor:Actor Core.vi.
03-21-2016 04:29 AM - edited 12-05-2024 09:00 AM
In my experiments with the AF Sample Projects I impoved my Cyclic Table Probes to show some internal object data (this is "Object Cyclic Table" probe):
Evap Cooler, Live User Controller, Actor:Actor Core incoming messages:
Live User Controller Actor object inside Actor:Actor Core:
I think this is a better method for a new user to explore an AF Sample Project, then having to identify which VI of many to place a breakpoint in, even if it may not be useful to an experienced AF user.
03-23-2016 05:44 PM
Just a note on the custom probe I just posted. You'll see that some of the messages seem to be missing data. That's actually because they are default data, and the LabVIEW flattening functions don't include a class's data if it is default (the probe uses "flatten to XML" as its way of breaking object encapsulation to query the data). Confusing, but not easily fixed.
03-30-2016 04:18 AM
Anyone try out this custom probe with AF messages? Useful? Improvements needed?
06-29-2017 03:47 PM
@drjdpowell wrote:
I just had a look at the two AF sample projects in LabVIEW 2015, "Actor Framework" and "Feedback Evaporative Cooler". They could do with improvement to help promote the AF to new Users. With neither project was it easily possible to open the block diagram of the main running actor.
Just a nudge, but I checked the "Actor Framework" sample project in 2017 and it is still ridiculously heavily armoured against the uninitiated. One has to have quite advanced knowledge to even open a running block diagram**. At the very least, please add "Open Block Diagram" to the menus of the top-level Actor.
**Unfortunately, the "click on Actor.lvlib:Actor Core and get the right clone" thing I previously mentioned doesn't seem to work in LabVIEW 2017.
06-29-2017 03:48 PM - edited 06-30-2017 05:17 PM
<double post deleted>
07-05-2017 06:01 PM
@drjdpowell wrote:
**Unfortunately, the "click on Actor.lvlib:Actor Core and get the right clone" thing I previously mentioned doesn't seem to work in LabVIEW 2017.
Known issue. Fix will be in the first patch. It's my personal screw up. Sorry.