Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 03-14-2007, 05:40 AM   #1
Registered: Aug 2003
Location: Melbourne Australia
Distribution: Fedora Core 4
Posts: 184

Rep: Reputation: 30
USB Optical Mouse as Position Sensor

Hi Again All,

I have been looking for a tutorial or howto or alike to show me how to use an optical mouse as a linear position sensor without having it plugged into a PC's USB port. Basically, I'm looking for some sort of information so I don't have to do all the fine detail learning myself.

I have skimmed over but this is far more than I wish to know to be able to use the optical sensor as a linear position sensor.

Without having to learn all the internal workings of the USB protocol & then all the mouse workings is there an easy way of acquiring just the X/Y motion information from an optical mouse, say by simply scanning for every 5th byte or bit (just grasping at thin air here!) or something?? I would like not to have the mouse plugged into a USB port but wired into a simple data acquisition PCB of my own design.

Hopefully One of you Linux / Electronics Geniuses's out there has done all the hard work for me & can point me in the right direction!

Old 03-14-2007, 07:10 AM   #2
Registered: Aug 2002
Posts: 14,749

Rep: Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476Reputation: 1476
IMO it would be easier using a PS/2 mouse since you do not need to worry about the HID protocol. A PS/2 uses a serial protocol. There is information on the web that describes the protocol as well as connecting a mouse to a microprocessor.
Old 03-17-2007, 12:35 AM   #3
Registered: Aug 2003
Location: Melbourne Australia
Distribution: Fedora Core 4
Posts: 184

Original Poster
Rep: Reputation: 30
Thanks michaelk,

This is EXACTLY what I as looking for!!

PS/2... hadn't even thought about using that & is obviously a much simpler way to go.

Thanks again!


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
optical mouse as a motion sensor - writting an aplication in C++ using Linux alexandre_fs Programming 6 01-27-2008 09:25 PM
usb optical mouse ftbreak Slackware 5 02-05-2005 08:24 PM
Use a usb optical mouse nmares Linux - Hardware 3 09-08-2004 01:42 AM
Logitech USB optical mouse fails with flaky usb tisource Linux - Hardware 2 06-20-2004 11:26 PM
Logitech Mouseman Optical Duel Sensor does not work limdeswein Linux - Hardware 8 02-13-2004 06:42 PM

All times are GMT -5. The time now is 01:09 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration