From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
03-21-2014 08:49 AM
Hi,
Is there an easy way to re-use an existing DesignPattern template and use it as basis for a new pattern?
For example I want to modify the existing ActiveObjects_DynamicEvents.vi located in
"<Program Files> \National Instruments\LabVIEW2013\esource\Framework\Providers\Symbio_GDS\ClassProviders\DesingPatterns\ActiveObjects
and rename it to ActiveObjects_DynamicEvents_MyVersion and add functionality to the "MyVersion".
This video: http://goop.endevo.net/GDS/videos/MakingDesignPatterns/ gives good overview of how to start a new developing a new design. But It would be great to know how to re-use.
Thanks,
Roger
03-23-2014 04:44 PM
FYI, I added some functions after I created that video, so it's not complete.Start by creating your own copy of the e.g. "ActiveObjects_DynamicEvents" files and folders:
ActiveObjects_DynamicEvents.ini
ActiveObjects_DynamicEvents.vi
Folder: ActiveObjects_QueueQueue_SubVIs
Rename the files in the ini file and start changing stuff.
Design patterns are easy to test/debug, since they get dynamically loaded and fully unloaded when GDS is done with them. That means you don't need to restart LabVIEW between every modification.
Cheers, Mike
03-28-2014 11:49 AM
Hi Mike,
Thanks for the answer.
When I add these files to a dedicated project (to make it easier to rename and keep links) I get conflicts which are not resolvable. For example the file ActiveObjects_DynamicEvents_ProcessRepository_Native.vi couldn't be resolved ... it keeps pointing to the vi in the directory ..\Providers\Symbio_GDS\ClassProviders\DesignPatterns\ActiveObjects\ActiveObjects_DynamicEvents_SubVIs
So I added the ActiveObjects_DynamicEvents.vi and the VI's in the ActiveObjects_DynamicEvents_SubVIs directory to a LVproject and did a Source-distribution build (with "add Prefix" option set). Did some "saving and find vi" -actions (find VI's in EndevoProvider.llb and in ..ClassProviders\Provider_BaseClassInterface-directory) and I hadn't any "resolve-problems" anymore.
Now I found out that I had to rename VI-names inside constants in the My_ActiveObjects_DynamicEvents.vi ... did that but somehow I broke something ... But I was also wondering if I'm on the correct track ...
You say I just have to rename files and folders and modify the paths in the ini-file, but how does the My_ActiveObjects_DynamicEvents.vi know for example what process.vi (as template) it should use? There is no path to this vi inside the ini-file (?) or do I miss something?
Thanks,
Roger
03-30-2014 04:39 PM
Do you mind sending me the files, so I can have a look?
04-02-2014 02:44 AM
Hi Mike,
I Attached a zip file containing the LabVIEW-project mentioned in the above post.
Inside the design pattern configuration vi (Active Object Dynamic Events.vi) I added bookmarks to track the modifications I made to the original configuration vi.
one of the functionalities I wanted to add is a method for showing the BlockDiagram of the process.vi which is very handy during debugging. For that purpose I added a state CreateShowBDVI after the CreateWindowControlVI-state. I used the AddWindowControlVI-boolean as condition to decide if the CreateShowBDVI has to be added.
Thanks for looking into it.
Roger
04-02-2014 08:16 PM
That was not a hard bug to find 🙂
Remove the Space in front on the String " CreateShowBDVI". I guess you didn't find it, because you don't know how to debug this VI. It very easy actually, just but a break point on the BD and save the VI, and then try to apply the Design Pattern again.
04-03-2014 04:52 PM
Thanks for finding this "Space"-bug. That was the cause of the major error. And I found a couple more minor bugs (update name and Icon for example) using your debug-tip. It's working now. Great! I attached this version including the project-file. Thanks for your help. Cheers, Roger
04-03-2014 04:55 PM
No Worries, I'm glad you are playing with Design Patterns. It would be good to have a good repository of all different Design patterns out there.
04-03-2014 05:01 PM
BTW, I'm thinking about your ShowBD option. I solved that by placing the Process VI,inside a disable structure on my main VI's BD.Then I just Ctrl+DoubleClick on it to open up the BD, but that only works when the process is not a clone. If I like to open the BD for a clone, I just save a Break Point in the start of the process VI, so it automatically opens when it lauches.