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.

DQMH Consortium Toolkits Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Standard DQMH project / application

Solved!
Go to solution

It seems that every DQMH module that the scripting tool generates, includes 2 VI's that appear to be tailored directly for use in the application module that comes standard with DQMH. These 2 VI's are "Init Select Module Ring.vi" and "Update Select Module Ring.vi". If that is the case then I suppose I am best off using the standard DQMH project layout for any new application. Now I know i can make use of the "Select Module" ring control in other ways in my own top level applications (other than the state machine that comes standard). Is my understanding of how these 2 VI should be used correct?

0 Kudos
Message 1 of 5
(3,732 Views)

Hi Rafal,

 

You can add a DQMH Module to any project. The API Tester shows how to use the DQMH Module API (all the public VIs that come with the DQMH module). The ring is the way we chose to address the cloneable modules, but the clone management code has its own library as part of your DQMH module and you can edit it as you wish. 

 

If you decide to use the clone module selection ring on your top-level application, you can use the code in the DQMH API Tester as an example of what to include in your top-level application.  Your top-level application can be another DQMH module, a simple VI or a state machine like in the DQMH Project Template. We chose a state machine because we wanted to highlight that the calling code does not need to be a DQMH module as well.

 

Regards,

Fab

For an opportunity to learn from experienced developers / entrepeneurs (Steve, Joerg, and Brian amongst them):
Check out DSH Pragmatic Software Development Workshop!

DQMH Lead Architect * DQMH Trusted Advisor * Certified LabVIEW Architect * Certified LabVIEW Embedded Developer * Certified Professional Instructor * LabVIEW Champion * Code Janitor

Have you been nice to future you?
0 Kudos
Message 2 of 5
(3,705 Views)

thank you for the response. I maybe didn't articulate my question correctly, and so allow me to rephrase. I've always assumed that each DQMH module was its own... I don't know what to call it... let's say... its own computational unit, and that the only way to communicate with it was via its Public API. I didn't find the "Update Select Module Ring.vi" or the "Init Select Module Ring.vi" in the Public API. I found them in the Multiple Instances / Module Ring virtual folder of any clonable module. If these 2 vi's are meant for public use, why wouldn't they be located in the Public API of the module? So then I began to think, well.. perhaps that is because Delacore wanted me to just use the example project structure verbatim as the staring framework for any new application. So that's why I asked the original question the way I did.

0 Kudos
Message 3 of 5
(3,702 Views)
Solution
Accepted by topic author Rafal_Kor

@Rafal_Kor

The Multiple Instances virtual folder is public. Within it, the Update Select Module Ring.vi is public, as well as the Init Select Module Ring.vi. This means any code outside of the module can call these VIs. We used this public scope to indicate that these VIs could be called form the outside world. One way to see at a glance what can be called from the outside world is to set the properties of the DQMH module as locked with no password (right-click on the module and select Properties. On the Properties window go to the Protection category and select Locked).  You will have to set the Clone Registration library as locked as well. This shows all the VIs that are accessible by the outside world:

 

Locked Cloneable DQMH Module.jpg

 

 

 

 

The documentation section "DQMH Singleton Module vs Cloneable Module Overview" describes the Multiple Instances folder and states "The cloneable DQMH module comes with a group of VIs to update a Module ID ring that can be used in the Tester or in the Application code to address the different instances of the module."

 

That said, I agree that having the Multiple Instances folder outside of the Public API might be misleading. I did a quick test and moving the Multiple Instances folder into the Public API seems to work. I ran the validate DQMH module tool and it was still recognized as a DQMH module. If you think we should make this change, feel free to add your feature request and point in the comments to this discussion. In the meantime, you could create your own Cloneable DQMH Module template that has this change and all your DQMH modules created from that template will have the Multiple Instances folder inside the Public API folder.

 

Thanks,

Fab

For an opportunity to learn from experienced developers / entrepeneurs (Steve, Joerg, and Brian amongst them):
Check out DSH Pragmatic Software Development Workshop!

DQMH Lead Architect * DQMH Trusted Advisor * Certified LabVIEW Architect * Certified LabVIEW Embedded Developer * Certified Professional Instructor * LabVIEW Champion * Code Janitor

Have you been nice to future you?
Message 4 of 5
(3,693 Views)

yet again, Delacor never fails to deliver quick and to the point answer. thank you,

Message 5 of 5
(3,658 Views)