LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

set the LED more than once

Hi

1.   I am doing a program that has a flat sequence structure. It has a LED in the first frame and I want to set this LED again after that in another frame. How can I do that?

2.   the program also has some controls that I want to check continuously and at any instance if the user change the values of these controls to unacceptable input the program indicates an error by the LEDs regardless of which frame is currently executed.

 

Can anybody help, please?

0 Kudos
Message 1 of 9
(3,202 Views)
Set a local variable for the LED
 
 

Message Edited by Steve.Briggs on 10-31-2007 01:00 PM

0 Kudos
Message 2 of 9
(3,196 Views)
Even better, redesign your flat sequence as a state machine and place the LED to the right of the case structure. Now you can write to it after each state without any need of local variables. 🙂
0 Kudos
Message 3 of 9
(3,188 Views)
what about the second question?
0 Kudos
Message 4 of 9
(3,179 Views)
use an event structure with value change events for each control. If the new value is unacceptable change the LED.
Jeff


Using Labview 7 Express
0 Kudos
Message 5 of 9
(3,173 Views)
The second "question" isn't much of a question at all but rather you telling us you have controls that at some times, give you errors.
 
We need to know what types of controls these are, posting your code will help.
0 Kudos
Message 6 of 9
(3,172 Views)


@student 999 wrote:
what about the second question?

Use a second parallel loop with an event structure.

Maybe you should show us your code. The description is too diffuse to decide what the best solution would be.

0 Kudos
Message 7 of 9
(3,169 Views)

first of all thanks alot for all your help

second what I mean is that I am trying to design a system to turn on a two pumps if the input pressure P1 >3  and the temperature <100 , if that happens then another frame will start executing , if at any instance P1 becomes ❤️ and/or temperature >100 I want to indicate an alarm with the LED

 

If I finish the VI I will post it

 

0 Kudos
Message 8 of 9
(3,164 Views)
here is a sample that I think is what you are looking for. I only posted the picture since I work with LV 7.0 and you probably dont have that.
notes:
1)If you have more than one extra "frame" change the layout to a state machine, it will be much easier to maintain and will look (not to mention function) a lot better.
2) There is a hidden event in the event structure...you should be able to figure it out, its basically the same as the shown one, except for the temperature.
3) I dont know where you are getting the pressure and temperature from, but you will need to update them between iterations of the loop.
4) Replace Done with whatever is your ending condition for your program.
Jeff


Using Labview 7 Express
0 Kudos
Message 9 of 9
(3,144 Views)