LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Writing and reading data with the PS/2 port

Hello Everybody, 

 

I am attempting to write and read data through the PS/2 port in order to communicate with a optical mouse sensor (not the actual mouse controller I rewired it to send data directly to the sensor chip). I need to write two bytes of data to the sensor in order to write data then write one byte and read one byte in order to read the data. 

 

From what I have sort of pieced together is that I might be able to accomplish this by using similar methods as you would to communicate with a parallel port, that is using the in port and out port vis. Is this correct? If it is I am not sure what address to use to communicate with the PS/2 port for these VIs.

 

I was also wondering if it is possible to use an adapter, say for RS232 or USB to accomplish this with more ease?

 

If anyone could let me know how I might be able to do this I would really appreciate it.

 

Thank you,

 

Eric

0 Kudos
Message 1 of 2
(1,348 Views)

Eric:

If you refer to the LabVIEW Help notes for more information on the out port.vi, you can see that it accepts
16 bit port addresses. At the bottom of the page, there are some example locations listed for sample code
using these vis. If you open the Parallel Port Read and Write Loop VI example, you can read through instructions
for Parallel Port Read and Write. The instructions with this example show you how to set up the device and
configure the address, likely found in the BIOS. Note that these VI's may not work on certain operating systems,
notably Windows Vista and Windows 7.

If you have any more questions, please also reply back with your operating system, LabVIEW version and what
driver/driver versions you have. That way I can have a more complete view of your setup.


Tori W.

National Instruments
0 Kudos
Message 2 of 2
(1,332 Views)