View previous topic :: View next topic |
Author |
Message |
XSquared n00b
Joined: 17 Feb 2004 Posts: 21
|
Posted: Mon Mar 01, 2004 9:38 pm Post subject: Serial Mouse |
|
|
What kernel options/modules do I have to enable to get a mouse working through a serial port on my PC (gentoo-sources-2.4.22)? |
|
Back to top |
|
|
spam_ Tux's lil' helper
Joined: 14 Jan 2004 Posts: 105 Location: /dev/null
|
Posted: Mon Mar 01, 2004 11:55 pm Post subject: |
|
|
None really for the mouse itself. But do make sure that your serial port driver is compiled in, by default it will be unless you're using some special serial controller (like a USB to serial adapter or similar).
You'll need to set up X/gpm to use /dev/ttyS0 (first port) or /dev/ttyS1 (second port) for the mouse device, depending on where your mouse is attached of course. |
|
Back to top |
|
|
kyonos n00b
Joined: 04 Nov 2002 Posts: 48
|
Posted: Wed Mar 03, 2004 1:30 am Post subject: |
|
|
Hi,
spam_ wrote: | None really for the mouse itself. But do make sure that your serial port driver is compiled in, by default it will be unless you're using some special serial controller (like a USB to serial adapter or similar).
You'll need to set up X/gpm to use /dev/ttyS0 (first port) or /dev/ttyS1 (second port) for the mouse device, depending on where your mouse is attached of course. |
So, if I have an USB to serial adapter, what do I need to do? (Which I assume, USB mouse, but have an adaptor to connect to the mouse connector on mobo) |
|
Back to top |
|
|
spam_ Tux's lil' helper
Joined: 14 Jan 2004 Posts: 105 Location: /dev/null
|
Posted: Wed Mar 03, 2004 2:12 am Post subject: |
|
|
kyonos wrote: |
So, if I have an USB to serial adapter, what do I need to do? (Which I assume, USB mouse, but have an adaptor to connect to the mouse connector on mobo) |
If the mouse itself is a USB mouse, and it has an adapter to the serial port you shouldn't need a driver as it should emulate a regular serial mouse.
What I meant is if you have a USB serial port device, which would plug into the USB port and give you a serial port, to which you plug a real serial mouse then you'd need a kernel driver to get the serial port to work before you can read mouse data off it. |
|
Back to top |
|
|
XSquared n00b
Joined: 17 Feb 2004 Posts: 21
|
Posted: Wed Mar 03, 2004 8:36 pm Post subject: |
|
|
Hmm... serial support is compiled into the kernel, but when I cat /dev/ttyS0 or /dev/ttyS1, I get nothing. Any ideas? |
|
Back to top |
|
|
spam_ Tux's lil' helper
Joined: 14 Jan 2004 Posts: 105 Location: /dev/null
|
Posted: Wed Mar 03, 2004 9:05 pm Post subject: |
|
|
XSquared wrote: | Hmm... serial support is compiled into the kernel, but when I cat /dev/ttyS0 or /dev/ttyS1, I get nothing. Any ideas? |
This is going to sound pretty obvious but... you have a device connected to the port which sends data, correct? Mice probably don't report data unless they're moved or a button's state is changed...
Also - that may or may not work correctly because you haven't set the baud rate of the serial port. If you get data, it will probably be garbage unless the device just happens to transmit at the same baud, parity, etc. the serial port is currently set to.
dmesg might be helpful in determing which ports exist and are recognized by the kernel. |
|
Back to top |
|
|
XSquared n00b
Joined: 17 Feb 2004 Posts: 21
|
Posted: Sat Mar 06, 2004 6:53 pm Post subject: |
|
|
dmesg is showing that the kernel is recognizing both of my serial ports, but it's just not getting any data from either of them (and yes, I'm clicking/moving the mouse, and yes, it works on Windows on that PC). |
|
Back to top |
|
|
|