Previous in Forum: Anti Virus for Trojan Horse Virus   Next in Forum: Who Can Help Me?
Close
Close
Close
8 comments
Associate
United States - US - Statue of Liberty - New Member Engineering Fields - Electrical Engineering - New Member Popular Science - Genetics - New Member

Join Date: Nov 2011
Posts: 36

Manipulating Values of LabView User Controls

04/02/2012 5:02 PM

I am a VB developer who is now having to learn LabView for work. on my current project I need to have a whole bunch of switches that I have put in to a cluster for the user to control. I would also like another switch that sends the program in to automated mode and will do the users job for him based on some parameters he presets. while it is doing this I would like the switches to actually toggle on the screen so the user can monitor the process. My question is how do you make the program take operate a user control and how do you return control to the user?

Register to Reply
Interested in this topic? By joining CR4 you can "subscribe" to
this discussion and receive notification when new comments are added.
Guru

Join Date: Mar 2007
Location: at the beach in Florida
Posts: 31557
Good Answers: 1744
#1

Re: Manipulating Values of LabView User Controls

04/04/2012 2:43 AM
__________________
Break a sweat everyday doing something you enjoy
Register to Reply
Guru
Popular Science - Cosmology - New Member Technical Fields - Technical Writing - New Member Engineering Fields - Energy Engineering - New Member Engineering Fields - Electrical Engineering - New Member Engineering Fields - Control Engineering - New Member Engineering Fields - Electromechanical Engineering - Old Member, New Association

Join Date: Apr 2008
Location: Lexington, KY
Posts: 1639
Good Answers: 72
#2

Re: Manipulating Values of LabView User Controls

04/04/2012 10:27 AM

I've only used LabView only sparingly, but I think I can help. Currently, I am using more Beckhoff controls and I find it to be easier to use. So, having done a similar routine, perhaps this advice will translate to something you can use.

First I created the "Auto" mode which latches up with ether external switch activation or with a graphical button "virtual switch". I soon took advantage of other graphical devices, some of which were display only, and some which would interact as a command switch.

Obviously you need to display the "status" of the other switches, but as to how they are controlled or actuated, you will have to decide. You may want parallel inputs where the virtual switches only toggle the "status" if you are in full automatic, thereby ignoring the physical devices. If you switch back to operator controlled mode, he will have to match those settings before taking over or predictable but undesirable things may occur. If it can happen, it will.

You could actually have a routine that checks the external hardware before allowing an operator to take over. It sounds like you have a lot of decisions to make.

Best of luck!

__________________
A great troubleshooting tip...."When you eliminate the impossible, whatever remains, however improbable, must be the truth." Sir Arthur Conan Doyle
Register to Reply
Associate
United States - US - Statue of Liberty - New Member Engineering Fields - Electrical Engineering - New Member Popular Science - Genetics - New Member

Join Date: Nov 2011
Posts: 36
#3

Re: Manipulating Values of LabView User Controls

04/04/2012 3:37 PM

Solar Eagle, That was not exactly what I was looking for in this thread, However it was something I was looking for to help with this project so thank you. Not Ur ordinary Joe, I think I have found a tool that will work well for me called a local variable. It allows you to have two different graphics on your programing screen one of which being an input the other being an output. If anyone else is looking for the same thing and stumbles across this thread be warned. If used properly local variables can be very useful, but it is easy to create race conditions within your program if your case and event structures are not considered carefully.

Register to Reply
Anonymous Poster #1
#4

Re: Manipulating Values of LabView User Controls

04/05/2012 11:44 AM

I worked with LabVIEW quite a bit a few years ago -- v7.1, mostly.

One big difference you've no doubt noticed between LV and VB is that LV is data driven.

In the end, to start and stop the process you are trying to achieve is no different from VB, in that you have to set a condition(s) to be met to start and stop either a While or For loop. I would think you could do it with a Global variable.

Your best bet is to utilize the NI forums and poke around there. I was lucky enough to find someone in those forums who then became my LV email buddy. I learned a lot from him. The LV engineers monitor the forums, too.

Register to Reply
Associate
United States - US - Statue of Liberty - New Member Engineering Fields - Electrical Engineering - New Member Popular Science - Genetics - New Member

Join Date: Nov 2011
Posts: 36
#7
In reply to #4

Re: Manipulating Values of LabView User Controls

04/06/2012 1:39 PM

Thanks for the advice

Register to Reply
Guru
Popular Science - Weaponology - New Member Hobbies - Fishing - New Member

Join Date: May 2007
Location: Aloha or
Posts: 581
Good Answers: 17
#5

Re: Manipulating Values of LabView User Controls

04/05/2012 5:41 PM

get a hold of national instruments techs. they are very good at helping out with their product. If you have a legal version it is free. The number will be with your CDs or I am sure it is available on line.

__________________
Closed biased minds are utterly impervious to any factual evidence which contradicts their beliefs
Register to Reply
Associate
United States - US - Statue of Liberty - New Member Engineering Fields - Electrical Engineering - New Member Popular Science - Genetics - New Member

Join Date: Nov 2011
Posts: 36
#6
In reply to #5

Re: Manipulating Values of LabView User Controls

04/06/2012 1:39 PM

I plan on contacting them but when my company was deciding what language to use for this project they got the trial version to see what LabView had to offer. I have programing in that while I wait on those above me to settle P.O.'s and paper work so I can get the real deal. So I will contact them but it will be at least a week before I have an actual license key. It is however reassuring to know that when I do contact them that they actually have decent support

Register to Reply
Power-User

Join Date: Jan 2010
Location: Dayton Ohio
Posts: 257
Good Answers: 10
#8

Re: Manipulating Values of LabView User Controls

04/13/2012 3:45 PM

I was able to teach myself how to program in Labview because of the support of the ni.com website examples and the "Show Context Help" popup. On the menubar, click on the Help and select Show Context Help. This will offer a brief overview of whatever your cursor is over in the program, including functiuons you are looking at in the programming menu. More in depth explainations are available by clicking on the "Detailed Help" link in the context help window.

For your program, I would parse a text file or a database file for settings, and use local variables to populate the controls with predetermined values. Because they are controls and not indicators, the user could change the values if needed. I would also record all the settings and resulting data in a logfile for the test so your production processes can easily be studied for optimization

__________________
MikeMack747
Register to Reply
Register to Reply 8 comments
Interested in this topic? By joining CR4 you can "subscribe" to
this discussion and receive notification when new comments are added.
Copy to Clipboard

Users who posted comments:

Anonymous Poster (1); MikeMack747 (1); NotUrOrdinaryJoe (1); redJohn75766 (3); silvCrow (1); SolarEagle (1)

Previous in Forum: Anti Virus for Trojan Horse Virus   Next in Forum: Who Can Help Me?

Advertisement