Austin Posted August 24, 2020 Report Posted August 24, 2020 (edited) I recently ran into this issue and wanted to know what the community has to say about it. I have a main program that is a QMH that can launch a single actor (picked by the main program and loaded through PPL) to perform a task. I want to have that actor update a CVT for the main program to monitor. I set up the CVT in the main program and had the actor write to CVT. When that call happens I get an error that it can't find that tag in the CVT. I have a CVT viewer that shows that exact tag, though. For testing, I setup the CVT in the actor with the exact same tag list and it finds it just fine. This leads me to believe that the QMH main program lives in a different memory space from the actor. (Maybe things loaded through a PPL live in different memory?) The current work-around is to send the value back to the main program. I don't really like doing that but it is what it is. My next option will be to convert the main program to an actor and see if the child actor can see the CVT setup by the main actor. Any thoughts on this? Maybe I'm doing something wrong? Edit: Tested a QMH with an actor called directly, instead of through a PPL and the actor can see the CVT without error. Next up, trying a packed actor called directly instead of loaded dynamically. Edit 2: Created a trivial PPL actor and called it directly from the main program and it could not see the CVT. Is there a good workaround for this? Edited August 24, 2020 by Austin Quote
drjdpowell Posted August 25, 2020 Report Posted August 25, 2020 I've never used PPLs, but my understanding is that they can only externally call other PPLs, and will include copies of any source code they call, including the Action Engine VIs that the CVT is based on. To use the CVT for communication, one would need to make a PPL out of the CVT and call that from both your other PPL and the main program. 1 Quote
Austin Posted August 25, 2020 Author Report Posted August 25, 2020 10 hours ago, drjdpowell said: I've never used PPLs, but my understanding is that they can only externally call other PPLs, and will include copies of any source code they call, including the Action Engine VIs that the CVT is based on. To use the CVT for communication, one would need to make a PPL out of the CVT and call that from both your other PPL and the main program. That seems perfectly reasonable, thank you. I created a new project to package up the CVT library so I could include this in my other project. When I try to load the PPL it also loads the original vi.lib CVT library and throws an error that Template_Read.vi could not be loaded because it could not load the front panel. When I look in the library itself all of the VIs in the Internal/Template Functions/ folders are missing except a few. This seems to be preventing me from building the main project, as it throws a file missing NULL error. I've gone back to the CVT PPL project and tried adjusting the exclusion settings to include everything but it still removes them. Any idea how to deal with this? Quote
drjdpowell Posted August 25, 2020 Report Posted August 25, 2020 3 hours ago, Austin said: Any idea how to deal with this? You've reached the limit of my understanding of PPLs, other than they sound like a pain. 1 Quote
Austin Posted August 25, 2020 Author Report Posted August 25, 2020 @drjdpowell thank you for your time and what you shared. Nice to confirm what I was thinking, but in a more coherent way. Quote
pawhan11 Posted August 26, 2020 Report Posted August 26, 2020 In one project we had setup with CVT ppl in main app, main all loaded plugins by PPLs and those plugins get/set some data in this CVT lib. It worked fine without problems. This CVT was based on simple FGV. Quote
Austin Posted August 26, 2020 Author Report Posted August 26, 2020 Was this a custom CVT library or the standard NI one? I spent most of yesterday trying to figure out the issues with packaging the NI one, with no luck. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.