LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using feedback node or shift register in while loop

Hello, I want to write a LabVIEW program that uses while loop and a case structure to flash the light for 3 seconds for only the first iteration of the while loop (i=0), and for other iterations (i>0) flash the other light continuously until I stop the program. I am new to LabView and I don't know how to use feedback node and shift register yet. Can you help me with the code?

0 Kudos
Message 1 of 4
(336 Views)

I'm not entirely sure I understand your requirements. But you can "flash" an LED indicator with the blinking property node.

 

Screenshot 2024-07-12 151704.png

0 Kudos
Message 2 of 4
(315 Views)

Thanks for your help. This is what I did and it worked for me. I didn't have to use a feedback node or the shift register.

Screenshot 2024-07-12 at 7.05.37 PM.png

0 Kudos
Message 3 of 4
(290 Views)

@Likusha wrote:

Thanks for your help. This is what I did and it worked for me. I didn't have to use a feedback node or the shift register.

Screenshot 2024-07-12 at 7.05.37 PM.png


This is still poor. We also cannot see most of your code (e.g what's in the other case or outside the cropped area.

 

You also need to define what you mean by "flash for 3 seconds. Blink n times over 3 seconds? Have it True for 3 seconds? Something else?)

 

Your indicator belongs outside the case structure. There should never be long waits, etc. all you probably need is a proper state machine that changes state based on elapsed time.

 

Please attach your VI and we'll fix it.

0 Kudos
Message 4 of 4
(260 Views)