10-17-2010 09:00 AM
Hi all
I've a problem in the posted program......
I need to stop the lap time when the lap progress is = to 0 ( when the indicator is on 10) only once time per lap !!!!
1 lap progress => 1 lap time
At the moment I feedback a lot of lap time because the VI's continue stop the time during all the duration of the transaction.... Please help me!!!
10-17-2010 10:19 AM
I don't understand what you are asking for, but here are a couple tips that would help you with your code.
1. Initialize the shift registers. If you don't, the value coming out of them on the first iteration of the while loop will be whatever was put into it the last time the code ran. So in effect, you might get a different result depending on whether the VI has run before or not.
2. Don't do a comparison of doubles with zero. At least nothing where you expect it to be exactly equal to zero. You have two time stamps, an initial time stamp plus some seconds, and the current time that you subtract from each other which you then compare to be less than zero. Since it is unlikely the subtraction will ever be exactly zero, it could be slightly more or slightly less, you may wind up with one more iteration than you expected.
10-18-2010 02:48 AM
I don't understand very well..... could you modify my VI?
Thanks
10-18-2010 07:11 AM
See if this explains somewhat.
/Y