04-21-2022 06:40 AM
Referring to CML DQMH shipping example, DQMH 6.1 specifically CML Main.vi ;
What does the launcher tool do to assist debugging? What types of bugs may it catch?
Please compare and contrast to the Test CML API.vi, the tester for CML UI and what would be different if the Startup vi was CML UI - Main.vi. I have only found similarities. Am I correct the Testers can be used as "Sniffers" after Build_Final_EXE, but the CML.Main cannot?
Note, I have not built the .exe yet, please let me know if I might figure out more by doing that and running the .exe .
The front panel comment "See the Build_Final_EXE bookmarks on the diagram for instructions on using this VI as a launcher for an EXE." refers to "bookmarks" where only one is found which appears to explain what the VI does, but not "instructions on using it as a launcher". Are the instructions implied by including the call to Pre-Build Action.vi in the pre/post build actions of the build specification?
Thanks
- Jared
05-02-2022 02:54 PM
Hi, CML Main.vi is the launcher of the CML application because it has some command line argumets that will allow you to debugg and troubleshot your executable application. Please follow these steeps:
CML
05-06-2022 09:01 AM - edited 05-09-2022 09:08 PM
Hi Jared,
To add to what Enrique already included.
The CML Main can be used also as a springboard for other applications to have a debugger. We normally add more buttons to it that allows us to launch all the individual API Testers for all the DQMH modules in the application. Also, the main UI may not be reporting errors and status messages and you are able to see those via the debug window.
We call it a debugger because it is hidden when you run the executable, it does not even show up on the taskbar (you can look at the documentation on the block diagram as to how we achieve that and you can look at the build specification for the Pre-build VI we use that is also included in the project). However, as Enrique mentioned, if you drag the exe to a command prompt and add -- debug as the argument, you have access to this screen.
Moreover, we use BLT to distribute our executables, we add the BLT error reporting to this top-level VI, which means that when we get an error report from BLT, we get to see the contents of the status indicator and that in turn tells us what happened before the error occurred.
You can find more details at https://documentation.dqmh.org/DQMHCMLSampleProject.html
Regards,
Fab
05-06-2022 09:34 AM
@FabiolaDelaCueva wrote:
The CML Main can be used also as a springboard for other applications to have a debugger. We normally add more buttons to it that allows us to launch all the individual API Testers for all the DQMH modules in the application. Also, the main UI may not be reporting errors and status messages and you are able to see those via the debug window.
This is one of the best features. If you have hardware, you can use the API Tester to test communication with the hardware module without launching the rest of the code. It's a built in manual test panel. You don't have to write any additional code (you are already maintaining the tester), except adding the launch code. Very useful for debugging.
I've also used it to enable/disable simulation for testing things without hardware or doing demos.
07-20-2023 05:21 AM
If I wasn't going to have an API launcher, and I just wanted Main.vi (in CML UI.lvlib) to launch at startup, is it "OK" to have that Main.vi as my only startup in the EXE ?
I ask as I am learning DQMH and need to wrap my head around viable options.