DISCLAIMER: First post, have a lot to say ![Smiley Happy Smiley Happy]()
Hello fellow Labview developers, students, and teachers. I have been using Labview on and off over the past year at a defense tech company; I've helped automating box level test sets for radar and automating board level test sets for acceptance testing. I am working on my first program that is entirely my own, so I made sure I went back and made sure my fundamentals were solid. I completed training core 1 and 2, and have read through a solid chunk of core 3. Ton's of great info that I incorporated into my program. I will now give a quick program overview for you guys before asking a few questions.
The aim for the program is run a specified test (most of the individual test code has been completed, e.g. a receiver test in which I communicate with a signal generator and the board and check linearity across the dynamic range) and format the data appropriately for a datasheet, all while logging system status with info from constant polling of the board. Implementing this gave me great insight into how to use parallel loops, tricks to prevent read-write-modify issues such as FGVs or encapsulating primitives into non-reentrant VIs, etc.
I have created a write config and read config VI.. the Read config VI reads from a config.ini text file which contains the VISA profiles and global constants and writes them to the programs globals. I want the user to be able to press a config button on the main vi front panel, set values for the controls which are the visa profiles and globals, have the values written to the globals, and then write the globals to the config file so its saved for next time the program is ran.
I've read that you should stay away from multiple parallel loops in one state, and stay away from multiple event structures in one loop. This was why I put the save graph function in its own unique loop and event structure. Also, its why I am hesitant to keep this structure and throw it into a state machine, with states being Idle, Config, Test&Log, and Done. OR, is this fine and how I should structure this program? (After thinking this through again, I will probably go this route if there aren't any objections).
Some other tidbits, I have been reading about different ways to control loops and stop them from a master button or loop. Currently, I have a master stop control directly connected to the test loop stop terminal, and there is an event structure in the other loops that checks for a value change on that master stop control, and then output a True to their loop stop terminals. Is this proper? Or should I possibly use a notifier setup?
In terms of one button dialogue true output being used to drive a case structure, is this OK? Or is an event structure better? Most of my tests for the receiver have to look at multiple channels, and I prompt the user to connect to the next channel with a one button dialogue, and the test only enters the test command loop once the button is pressed. I was curious about any issues this may have associated with it.
I chose to just share an image since I would have to clean up specific job info before upload, and I believe you guys can answer my questions off an image. I am willing to take recommendations on anything I did not mention as well, such as error handling. Thank you for your time, and I look forward to discussion and learning.