03-26-2020 03:01 PM - edited 03-26-2020 03:30 PM
Disclaimer: I'm new to Labview.
I've got a VI that pulls data from an unknown location (possibly a database) to configure itself depending on the circumstance. If it is pulling from a database, is it the CTL file that determines where the data is coming from? If so, how do I find where it's pulling it's data from so that it can be changed?
I'm trying to change the default data that auto populates because our hardware requirements have changed.
Below is the VI and the CTL file snip.
Thanks!
03-26-2020 03:30 PM
Hi Jay,
@JayWW wrote:
Disclaimer: I'm new to Labview.
Below is the VI and the CTL file snip.
Please read the LabVIEW help on "snippets" to learn the difference between plain images and real snippets…
(And do those Trainings as offered in the header of the LabVIEW board. NI even offers all courses for free until end of April!)
@JayWW wrote:
I've got a VI that pulls data from an unknown location (possibly a database) to configure itself depending on the circumstance. If it is pulling from a database, is it the CTL file that determines where the data is coming from? If so, how do find where it's pulling it's data from so that it can be changed?
I'm trying to change the default data that auto populates because our hardware requirements have changed.
This VI will read data from a GPIB device as configured in this "Supply settings" typedefined cluster.
This cluster contains several elements, which define the parameters of the GPIB communication, like GPIB address and power supply settings.
When you want to change the "where it's pulling data from" part, then you have to change the GPIB address…
(The underlined words can be found in the LabVIEW help: you surely want to learn LabVIEW and read its help!?)
03-26-2020 03:39 PM - edited 03-26-2020 03:40 PM
Hi Gerd,
So am I correct in assuming the configuration takes place in the CTL file? The GPIB devices are unconfigured (other than their address) prior to getting to this part of the code. It's a generic form that changes based on the GPIB address (I believe).
It's to configure two different power supplies that have different voltage and current levels. They are currently being configured incorrectly which causes the program to hang.
Thanks,
Jay
03-26-2020 03:41 PM
Hi Jay,
@JayWW wrote:
So am I correct in assuming the configuration takes place in the CTL file?
No, wrong.
The CTL file just defines the datatype of the control. (Strict typedefinitions also define the look/style of the control on the frontpanel.) But it does not define the value of the control!
@JayWW wrote:
It's to configure two different power supplies that have different voltage and current levels. They are currently be configured incorrectly which causes the program to hang.
Then you need to set correct values!
I guess the shown VI will be called from a main VI: you need to wire correct data to the "Supply settings" input of this VI!
03-26-2020 03:48 PM
When the VI gets called in the program, the window pops up with values already loaded. I'm trying to determine where the values are coming from, because in the VI the default values are zero prior to running the program.
So the VI is being sent values based on the GPIB address. These new power supplies need different values in order to be configured properly, but I can't find where the values are being stored. They aren't being entered by the user.
03-26-2020 03:54 PM
Hi Jay,
@JayWW wrote:
When the VI gets called in the program, the window pops up with values already loaded. I'm trying to determine where the values are coming from, because in the VI the default values are zero prior to running the program.
So there seem to be a data source in the calling VI that provides those "Supply settings" parameters. You need to find the place where the VI is called!
Hints:
(It really would help you when you start with LabVIEW tutorials before trying to analyze other peoples source code.)