LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Resetting parallel port

I'm working on an app that uses the parallel port to do a "walking ones"
to a logic device. Only the first four bits of the port are used, these
four
go thropugh a demux then to the device which has ten inputs. That part
works fine and the program itself works almost perfectly, except for one
item.

If the count is stopped in mid cycle (using a while loop to count to ten)

and then restart the program, the parallel port does not rest back to zero
it just keeps going where it left off. The only way to fix this problem now
is
to shut down labview (not an option).

How do I insure that the parallel port is zeroed at the begining of each
count cycle automagicly?

Thanks in advance!
0 Kudos
Message 1 of 3
(2,511 Views)
Are you using a shift register in your while loop? And if so, do you
initialize it? If you don't, it will remember the last value.

Tom Nathe wrote:
>
> I'm working on an app that uses the parallel port to do a "walking ones"
> to a logic device. Only the first four bits of the port are used, these
> four
> go thropugh a demux then to the device which has ten inputs. That part
> works fine and the program itself works almost perfectly, except for one
> item.
>
> If the count is stopped in mid cycle (using a while loop to count to ten)
>
> and then restart the program, the parallel port does not rest back to zero
> it just keeps going where it left off. The only way to fix this problem now
> is
> to shut down labview (not an option).
>
> How do I insure that the
parallel port is zeroed at the begining of each
> count cycle automagicly?
>
> Thanks in advance!
0 Kudos
Message 2 of 3
(2,511 Views)
On 16 Feb 2000 12:07:03 -0600, "Tom Nathe"
wrote:

>I'm working on an app that uses the parallel port to do a "walking ones"
>to a logic device. Only the first four bits of the port are used, these
>four
>go thropugh a demux then to the device which has ten inputs. That part
>works fine and the program itself works almost perfectly, except for one
>item.
>
>If the count is stopped in mid cycle (using a while loop to count to ten)
>and then restart the program, the parallel port does not rest back to zero
>it just keeps going where it left off. The only way to fix this problem now
>is
>to shut down labview (not an option).
>
>How do I insure that the parallel port is zeroed at the begining of each
>count cycle automagicly?

If i have under
stood this correctly i have two ideas:

-1-
If the while loop only counts to ten then send the value of the
iteration (i) terminal to the paralell port.

-2-
If the while loop count continually the send the value of the
iteration (i) terminal through Quotient & Remainder function (divide
by ten) and send the remainder to the paralell port. You may get a
problem when the iteration terminal reaches maximum value.
0 Kudos
Message 3 of 3
(2,511 Views)