LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

control parallel port (data and control lines)

I need to control the output on the parallel port (LPT1) - Both data and control lines.  Once the data is written (Pins2-9), I then need to toggle the Sprocket signal (PIN1) - on the parallel port. The sprocket signal is also referred to as the Data Strobe Output.

The required method is as follows:

1. Lower the sprocket signal on PIN1

2. Send the data (Pins2-9) and wait

3. Raise the sprocket signal and wait.

4. Repeat.

I am looking for a method to control the data on LPT1 pins 2-9 and then be able to toggle PIN1 - Strobe signal - without the data falling from the other pins. What I have found is that whenever the state is changed on the strobe - the data that was written to Pin2-9 falls to zero. This will not work for my application - the strobe tells the hardware device that the data is ready. If it falls to zero when I toggle the strobe - that will not work.

Regards,

Guy

0 Kudos
Message 1 of 3
(2,802 Views)
Hello Guy,

It is possible to use VISA to write data to the parallel port.  There is an example program on the web which does just that (the versions listed are older, but they should open with current software).  Also, you may want to take a look at this DevZone doc that discusses updating the parallel port in general. 

Hope this helps!

Adam W
Applications Engineering
National Instruments

0 Kudos
Message 2 of 3
(2,771 Views)
Hello Adam,
 
I am familiar with both references.  If you look more closely at the library reference - it allows me to communicate using VISA across the parallel port pins 2-9.  It does not permit direct communication to pin1 (the strobe signal) - property nodes don't allow the strobe to be refereced either (similar to control lines/signals for COM ports).
 
Worse, I have also located examples using OUT PORT that does enable pin1 to be toggled.  The problem is, when those VIs are used, the data falls from the data pins when the strobe signal is written, even if its value is not changed.  For example, if the strobe is already high, if another high value is passed, the data falls from the data lines.  The other issue, when using VISA, as soon as the data is writen, the strobe signal automatically goes high even though I need a wait before setting the strobe high.  This is in complete contradiction to the second article you referenced which clearly discusses writing data to pins2-9 then taking the strobe high to indicate to the printer that new data is available.  It must be possible since this is the typical handshake.
 
I am still looking for a more complete answer/solution.
 
Regards,
 
Guy
0 Kudos
Message 3 of 3
(2,763 Views)