LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I read the data from PS/2 port in order to store timing of mouse click?

I am using LabView 5 and later.
0 Kudos
Message 1 of 4
(2,925 Views)
One way you could do it is to create a picture control on your front panel. If you create an attribute node for the picture control then you can select "mouse" as the property of the attribute node. The node will output a cluster that reports mouse position, clicks, and modifiers. This info is reported any time there is mouse activity on the picture control.

Hope that helps.
SW
0 Kudos
Message 2 of 4
(2,925 Views)
Another method would be to use an event. The event would start a timer, or store a timer value based on the event. Of course, this is only available in LabVIEW 6.1, so you would have to upgrade.

The only possible issue with this is that you would have to deal with the resolution of the system clock, which isn't that good in Windows systems.

Let us know some specifics, and we may be able to help more. It would help to know why you are doing this, or what your exact requirements are (i.e. timing precision, what you are trying to time the mouse click with, etc.)
Message 3 of 4
(2,925 Views)
I have to read the data of response-box which has 2 outputs: serial and PS/2. For the serial output I use "read serial port.vi" (like "key master.vi" for the keyboard), but for the PS/2 port I need subVi or llb.
0 Kudos
Message 4 of 4
(2,925 Views)