LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Parallel Port?

Okay, after talking it over with my superviser we realized that the serial port wasn't going to work for our purposes, so now we're trying to talk to the parallel port. I'm using outport.vi off the advanced menu to send data to the I/O register 0378. Unfortunately this doesn't seem to be working. I double checked the register number and it is correct. Do I need to ground some pins on the parallel port connection to the circuit or what? I'm really unsure of what could be causing this to fail. Any help or suggestions would be greatly appreciated.
0 Kudos
Message 1 of 9
(6,265 Views)
Did you read all of the information regarding parallel port in your other post of the same question? There are pins that need to be grounded and the links provided in the other post tells you which ones. If you are working with LabVIEW 7 or higher, you can disregard the information on downloading the replacement for the inport/outport VIs.
Message 2 of 9
(6,264 Views)
Hi Kura,

Sometimes working with the parallel port can be a bit tricky... not difficult mind you, but a few "gotchas"..

I need to ask a few questions:

1. Are you using the standard parallel port? 0378 appears to be correct if that is the case. Additional parallel ports (PCI) have an address in a much higher range. This is unlikely the case.

2. EPP / ECP / Standard parallel port setting in your BIOS. Depending on what you are trying to do with the port, you may want to use the appropriate setting. Are you trying to send and receive data?

3. Yes, for signals, you need to connect to the appropriate ground pin. You can do a search on parallel ports to find the pinout.

4. Try simply writing and reading back the values without con
nection the port to anything. You can try the examples provided by NI. Which version of LV are you using?

5. Attached is some old info I have about the port. It can be interesting reading.

Try #4 and let us know of the progress.

-JLV-
Message 3 of 9
(6,264 Views)
Looks like my buddy Dennis beat me to the answer..

WOW.. lots of useful info on your other post.

Read the info & try the proposed solution.
Please post your progress using one of the two threads. (this one preferably).

Thanks Dennis!!

🐵
Message 4 of 9
(6,264 Views)
So then I need to ground the busy and error pin? I wasn't sure if this was necessary or not as a tutorial I found in ni.com said that it shouldn't be required for outport.vi based communication. Also, thanks for that link, I had forgotten about that post.
0 Kudos
Message 5 of 9
(6,264 Views)
Well, currently I've got a rig set up that should light up when I send a signal to pin 2 or pin 9. I've been writing to decimal 888 but it doesn't seem to be working since none of the led's are lighting up. The one thing that does bother me though is that when I go into device manager and look at the info for lpt-1 there are two I/O ranges listed:

0378-037F and 0778-077F

I'm not sure if that's abnormal or not, but I tried writing to hex 0778 and got no results either. Despite being told by a tutorial that grounding busy and error was unnecessary I think I'm going to try that and see what happens. Also, I've been using OutPort8.vi that I found under the advanced menu, I'm not sure if that's a problem or not, but its not generated any errors so I assume th
at its working. I'm using LabView 7 Express version 7.0 on Windows XP Pro
0 Kudos
Message 6 of 9
(6,264 Views)
Use 0378.

Have tried the parallel port example?

Open LV, Under "Help", select "Find Examples", and do a search under parallel (search tab & enter "parallel").

You will find 2 examples (maybe you already did this..)

1. Parallel Port Additional Data Register
2. Parallel Port Read & Write Loop.

Run either one. You should be able to set and read the port. There is a description in the example how to do this. Look at the "LEDs".

If you look at the first example, under the "IO connector Status" tab, you will find the D-sub pinout. If you run it, it will give you the present status of your pins.

They recommend using the Standard mode (SPP) setting in your PC's BIOS.

If you run the 2nd example, you can write & readback your
parallel port. Try this FIRST before attempting to communicate with your DUT. Note that having a printer connected to your port may result in some strange behaviour 🐵

Let us know of your progress.

-JLV-
Message 7 of 9
(6,264 Views)
Thank you all for your help, as it turns out, the original outport.vi was working fine, but one of the cables I was using was bad and was not transmitting a signal. I replaced the cable and now the VI is working fine. Once again, thanks for all of your help.
0 Kudos
Message 8 of 9
(6,264 Views)
Thank you Kura.

Glad everything is working well.

:O)
Message 9 of 9
(6,264 Views)