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.

Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

question from a beginner



@Dennis Knutson wrote:
Nothing happens at all? When I try it, it seems to work as designed. Of course I don't have the instrument connected but when I change a front panel control and run the VI, I get the serial write sending out commands.

The VI you've posted is designed to run as a subVI.




I am trying to connect this subVi to the "main ctrl" VI. In this subVi, there is a now a control for the volume of the pump. I would like to add this control to the two existing controls (load control and time control) of the "main ctrl". I cannot locate these two controls in the block diagram of the "main ctrl". Could you please help me do it? Thanks
0 Kudos
Message 41 of 108
(1,192 Views)
To find a control on a block diagram, you can double click the control with the postion/size/select tool (arrow pointer or right click the control and select find indicator. The load and time control is actually is single Boolean control.

p.s. I'm glad I don't have to edit or maintain the VI you posted. Way too hard to read. It violates just about every style guide I've ever seen. Wires everywhere and they don't go in any logical order, the right directions, hidden by other objects, etc.
0 Kudos
Message 42 of 108
(1,186 Views)


@Dennis Knutson wrote:
To find a control on a block diagram, you can double click the control with the postion/size/select tool (arrow pointer or right click the control and select find indicator. The load and time control is actually is single Boolean control.

p.s. I'm glad I don't have to edit or maintain the VI you posted. Way too hard to read. It violates just about every style guide I've ever seen. Wires everywhere and they don't go in any logical order, the right directions, hidden by other objects, etc.




Thank you very much for your advice. If it's a boolean, is there a way to add a third control to it? Do you know which kind of switch is used for the load and time control(button,text ctrl..)? Will that make the program more understandable if I use the function "clean up wires" on each wire, will that make the program more understandable?
0 Kudos
Message 43 of 108
(1,183 Views)
I'm not sure what you're asking. The front panel control load/time is a switch right in the middle of the front panel. All controls have a single output. They can have multiple values. A Boolean can only have a true/false value. Numerics can have any value between the specified range and data type. If you want to change the appearance of the front panel control so that it has three options, you'll have to replace it. One option might be with a toggle swithc that has 3 positions. Some examples of this have been posted recently here, here, and here. This type of control is really a numeric so you'd have to change some other things in the program.

Clean up wire might help some but it won't accomplish miracles. For one thing, you can't select all wires to do a clean-up on. You have to select them one-by-one. One thing you can do is make use of a cluster. When you pass upmteen different control values to a subVI, you have a lot of wires and the connector pane of the subVI is a mess. If you put them into a cluster on the front panel, then there's only one wire you have to pass to the subVI. Also, the convention is that data flows from left to right. That means an output from a function shouldn't go to the input of a function on the left side of the diagram. For other suggestions, I would recomend that you read the LabVIEW Style Guide that ships with LabVIEW. It's part of the LabVIEW Bookshelf that you can access from the help menu.
0 Kudos
Message 44 of 108
(1,178 Views)
Could you please tell me how to save a VI in 7.0 from a computer that has the 7.1 version? Thanks.
0 Kudos
Message 45 of 108
(1,225 Views)
File>Save With Options. Select the Save for Previous radio button.
0 Kudos
Message 46 of 108
(1,217 Views)


@Dennis Knutson wrote:
I'm not sure what you're asking. The front panel control load/time is a switch right in the middle of the front panel. All controls have a single output. They can have multiple values. A Boolean can only have a true/false value. Numerics can have any value between the specified range and data type. If you want to change the appearance of the front panel control so that it has three options, you'll have to replace it. One option might be with a toggle swithc that has 3 positions. Some examples of this have been posted recently here, here, and here. This type of control is really a numeric so you'd have to change some other things in the program

Thank you. I am now trying to change the 2 way switch into a 4 way switch. The example are for a three way switch. Is possible to have a four way switch in LabVIEW?
0 Kudos
Message 47 of 108
(1,150 Views)
The easiest option for you would be to use a slider. A slider can have any number of positions. If you right click on the slider, select Text Labels. You can then use properties to change your text labels. In LabVIEW 7.1, you also have the Radio Button control. You can have as many radio buttons as you want. Those 3 position toggle switches in the posts are picture controls if I remember correctly. Modifying one for 4 pictures instead of 3 can be done but I think the first two options would be easier for you.
0 Kudos
Message 48 of 108
(1,148 Views)
Hello.

The program “manual pump”, run a pump from the RS232 port. I have a displacement sensor attached to the ACH0 of a National Instrument PCI-1200. I need to modify the “manual pump” program such that I can get the displacement data. Could you help me to do that? I actually have a program (“read_displ”) to read the voltage from the ACH0 but it does not work. Thanks in advance.
0 Kudos
Message 49 of 108
(1,165 Views)
I forgot to attached "manual pump". Thanks
0 Kudos
Message 50 of 108
(1,149 Views)