tags:

views:

627

answers:

2

Here is my basic use case:

After Labview receives a trigger from external hardware start collecting analog data. It monitors this data and triggers another piece of hardware if the analog data reaches a threshold. This threshold can have different values for each trial. However, the operator might want to be able to redo a trial (if the trigger is sent to early because of noise or the threshold isn't reached as expected).

Is it possible to increment/decrement the index or do I need to use a shift register that I can either increment/decrement as needed (ie decrement it if the redo button is pressed)?

Thanks

Azim

+1  A: 

I think a shift register is your best bet if you don't want to use the autoincrementing index of the loop. This gives you the most flexibility in manually adjusting your index.

cschol
+4  A: 

Without getting into the nitty-gritty of your application and to answer your actual question, no, you can not affect the value that comes out of the index node in a for or while loop. It autoincrements by one for every loop iteration.

Application-wise, you may want to look into a State Machine. It sounds like you might be able to use that for what you're trying to do.

eaolson