LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Sequence tunnel error

Im having an intresting problem with sending out data from a sequence. Pls dont give me crap about using sequences cause this one is absolutely necessary for the hardware to work properly. Ok that said heres the problem. I have a sequence loop within a while loop. The while loop has a shift register on it used to remember a data value from one iteration to the next. The data value goes into the sequence struct where it is modified in the second frame and is then passed out through a tunnel in the same frame. Now the sequence completes the remaining frames 4 in total. Now when the data from the sequence should be passed back to the while loop, it has the proper data type (cluster with 2 I32 intergers within) but.... the data in the second I32 variabl
e has been modified. Actually its been decremented by 24. and if i enter the loop again it exits with another 24 decrement. Now this isnt the only variable i have leaving that sequence but its the only one that is changed when crossing the sequence border. All shift registers are properly inited. I am completely baffled. Im guessing that for some reason the latter frames have an effect on the tunnel value but i no idea why, nothing is connected to that tunnel in the later frames. Anyone got a clue whats wrong?
Using labview 6.1 on a Pent 400.
0 Kudos
Message 1 of 6
(3,175 Views)
I think that we're going to have to look at the code for this one. Can you post it or as much of it as we need to see what's happening? I can't seem to reproduce the problem here with the information that you gave us.

Rob
0 Kudos
Message 2 of 6
(3,175 Views)
Sound like you may need to add a sequence local to pass data to the second frame?

Cheers

"JoeDoe" wrote in message news:506500000008000000D0BE0000-1075935269000@exchange.ni.com...
> Im having an intresting problem with sending out data from a sequence.
> Pls dont give me crap about using sequences cause this one is
> absolutely necessary for the hardware to work properly. Ok that said
> heres the problem. I have a sequence loop within a while loop. The
> while loop has a shift register on it used to remember a data value
> from one iteration to the next. The data value goes into the sequence
> struct where it is modified in the second frame and is then passed out
> through a tunnel in the same frame. Now the sequence completes the
> remaining fra
mes 4 in total. Now when the data from the sequence
> should be passed back to the while loop, it has the proper data type
> (cluster with 2 I32 intergers within) but.... the data in the second
> I32 variable has been modified. Actually its been decremented by 24.
> and if i enter the loop again it exits with another 24 decrement. Now
> this isnt the only variable i have leaving that sequence but its the
> only one that is changed when crossing the sequence border. All shift
> registers are properly inited. I am completely baffled. Im guessing
> that for some reason the latter frames have an effect on the tunnel
> value but i no idea why, nothing is connected to that tunnel in the
> later frames. Anyone got a clue whats wrong?
> Using labview 6.1 on a Pent 400.
0 Kudos
Message 3 of 6
(3,175 Views)
I reread your question, maybe you can try adding sequence locals so that the data is passed out of the last frame. Or create a
local and assign it in frame 2 and pass the local out of the sequence in frame 4.

Cheers

"Martin Riddle" wrote in message news:QrCWb.858$WW3.698@newsread2.news.pas.earthlink.net...
> Sound like you may need to add a sequence local to pass data to the second frame?
>
> Cheers
>
> "JoeDoe" wrote in message news:506500000008000000D0BE0000-1075935269000@exchange.ni.com...
> > Im having an intresting problem with sending out data from a sequence.
> > Pls dont give me crap about using sequences cause this one is
> > absolutely necessary for the hardware to work properly. Ok that said
> > her
es the problem. I have a sequence loop within a while loop. The
> > while loop has a shift register on it used to remember a data value
> > from one iteration to the next. The data value goes into the sequence
> > struct where it is modified in the second frame and is then passed out
> > through a tunnel in the same frame. Now the sequence completes the
> > remaining frames 4 in total. Now when the data from the sequence
> > should be passed back to the while loop, it has the proper data type
> > (cluster with 2 I32 intergers within) but.... the data in the second
> > I32 variable has been modified. Actually its been decremented by 24.
> > and if i enter the loop again it exits with another 24 decrement. Now
> > this isnt the only variable i have leaving that sequence but its the
> > only one that is changed when crossing the sequence border. All shift
> > registers are properly inited. I am completely baffled. Im guessing
> > that for some reason the latter frames have an effect on th
e tunnel
> > value but i no idea why, nothing is connected to that tunnel in the
> > later frames. Anyone got a clue whats wrong?
> > Using labview 6.1 on a Pent 400.
>
>
0 Kudos
Message 4 of 6
(3,175 Views)
Ok guys here where I stand. I tried to pull the significant parts of the code out and put them in a new VI soo that i could post it to the board, but.... When i did so the new VI worked flawlessly. So i toyed around more removin parts of the sequence and different frames. I have narrowed it down to one specific area. Once the data was inside the sequence it goes to a subvi that is used for updating. This subvi output is the data is then fed to the hardware and fed to that tunnel thats giving me the trouble. Ok when the data leaves that subvi it goes to the output tunnel but it also goes to a sequence local to be used in a latter frame. This is the part thats causeing the change of data. If i remove that sequence local and instead use a local variable( i know another n
o no..) it works fine. Its as if the sequence local somehow interacts with the seqence tunnel. Im not sure if these data values are stored in the same memory spot or what but having that sequence local and the sequence tunnel have the same data value seems to screw everything up. For now im just going to use the local variable and be happy i have a work around. If i can figure out how to duplicate the problem ill post the code. I would post the entire VI but its got alot of hardware funcionality that im not sure what it would do to a system with out the hardware. Thanks for offering suggestions, they did lead me to a fix.
0 Kudos
Message 5 of 6
(3,175 Views)
One of the problems with the sequence structure is that data doesn't leave any of the frames until the last frame is done. I suspect that that is what you are seeing if the data is modifed in a later frame.
0 Kudos
Message 6 of 6
(3,175 Views)