LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1152|回复: 13

退出X后gpm的问题

[复制链接]
发表于 2004-1-5 17:03:49 | 显示全部楼层 |阅读模式
很多次退出X以后gpm就开始失灵。一动鼠标屏幕最上面就光标乱闪。而且会自己paste内容。如何解决?多谢!
鼠标为Logitech Optical Wheelmouse USB转换成PS2接口用. 在gpm里定义为ps2。

Slackware 9.1 with some current packages.
发表于 2004-1-5 22:00:00 | 显示全部楼层
我以前贴过一个方法吧,你找一下吧,在家,没linux用
发表于 2004-1-6 08:49:17 | 显示全部楼层
 楼主| 发表于 2004-1-6 10:54:10 | 显示全部楼层
但是我的鼠标在gpm里已经定义为ps2了。
发表于 2004-1-7 07:26:17 | 显示全部楼层
最初由 frenzy 发表
但是我的鼠标在gpm里已经定义为ps2了。


就是,而且我照了楼上的方法试过了,没用,在gpm的man page里说过这个问题,可是我找不到那个/dev下的目录。
发表于 2004-1-7 07:45:48 | 显示全部楼层

ZT

[UCLA-LUG] pointing device question
Frederick Lee phaethon@fire.csua.ucla.edu
Tue, 10 Aug 1999 16:49:43 -0700

Previous message: [UCLA-LUG] pointing device question
Next message: [UCLA-LUG] pointing device question
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

--------------------------------------------------------------------------------

Said James Lee <jwlee@seas.ucla.edu>:
>Thanks for your information.  I have tried selecting every single protocol
>there is but it's still giving me the same problem.  Any other reason why it
>wouldn't work?  I can't use Xconfigurator because of my video card.  Thanks.
>
>-James
>
>witten wrote:
>
[snip]
>>
>> Sounds to me like you're using the incorrect protocol for the mouse. When
>> I've had that problem before, I've just tried experimenting with different
>> mouse choices until I got the right one. Note that it's preferable to use
>> Xconfigurator instead of xf86config on Redhat 6.
>>
>> Dan

As a last resort, gpm can be used for the mouse data:

The General Pupose Mouse (gpm) program is that thingy used to show and use the
mouse in the text console.  It has a mode where it can take in the mouse data
and spit it out (translate) into Mouse System protocol.  It spits it out into a
named FIFO called "/dev/gpmdata".  There are some mouse protocols that gpm
understands that XFree86 can not, so gpm is useful in translating the unknown
mouse movements into something XF68 knows.  In the case of bus mice, to use the
mouse in both text console and X, gpm is pretty much required (something about
the bus mouse only allowed to be opened once).

To set gpm up as a repeater (the translation mode), create a named FIFO called
"/dev/gpmdata" (need to be root):

bash# mkfifo /dev/gpmdata


This FIFO should be chown'd to the uid of the gpm that will run.  In most
cases, it'll be root (by being exectued from an rc script):

bash# chown root /dev/gpmdata


Preferably, the FIFO should be chmod'd to 644, so that any random process won't
mangle mouse data, and it can always be read.

bash# chmod 644 /dev/gpmdata


Alternatively, just "chmod 666 /dev/gpmdata" without chown'ing if you don't
expect any rogue processes/users screwing around with the mouse data.


In X, set it to use Mouse System (I think) protocol, using /dev/gpmdata as the
device.


In the rc script (or whenever else gpm is being started), gpm needs to be
passed the "-R" (repeater) option.  On Red Hat (-based?) boxen, it's in
/etc/rc.d/init.d/gpm.  On Debian boxen, /etc/init.d/gpm.

Also, gpm would need to be configured to recognize the mouse first.  If
the mouse works in text console, no need to fiddle with that.  Otherwise...
umm... /etc/sysconfig/mouse in RH5.2, /etc/gpm.conf in Debian.


All this is documented somewhere in one of the HOWTOs, but I can't recall which
one.

-Fred

谁看懂了?
发表于 2004-1-7 07:47:08 | 显示全部楼层

还有

[UCLA-LUG] pointing device question
James Lee jwlee@seas.ucla.edu
Wed, 12 Aug 1998 20:26:22 -0700

Previous message: [UCLA-LUG] pointing device question
Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

--------------------------------------------------------------------------------

Thanks guys..It is finally working now!!  You guys are the best.

Brian Vicente wrote:

> I had something similar before .
> Here's my setup for a ps2 style Microsoft IntelliMouse:
>   Protocol    "IMPS/2"
>     Device      "/dev/mouse"
>     ZAxisMapping 4 5
> I don'tthink this is a choice ucing the xf86configurator
> I also have :
> /dev/mouse -> psaux
>
> Hope this helps
>
> >On Mon, 10 Aug 1998, you wrote:
> > Is this only for console mode?  I tried this but no luck....perhaps, I should
> > mention that my mouse works fine in console mode but not in xwindows?  Sorry guys,
> > but I am so eager to get this working so I can finally taste Redhat 6.0!  Thanks.
> >
> > Frederick Lee wrote:
> >
> > > Said James Lee <jwlee@seas.ucla.edu>:
> > > >Thanks for your information.  I have tried selecting every single protocol
> > > >there is but it's still giving me the same problem.  Any other reason why it
> > > >wouldn't work?  I can't use Xconfigurator because of my video card.  Thanks.
> > > >
> > > >-James
> > > >
> > > >witten wrote:
> > > >
> > > [snip]
> > > >>
> > > >> Sounds to me like you're using the incorrect protocol for the mouse. When
> > > >> I've had that problem before, I've just tried experimenting with different
> > > >> mouse choices until I got the right one. Note that it's preferable to use
> > > >> Xconfigurator instead of xf86config on Redhat 6.
> > > >>
> > > >> Dan
> > >
> > > As a last resort, gpm can be used for the mouse data:
> > >
> > > The General Pupose Mouse (gpm) program is that thingy used to show and use the
> > > mouse in the text console.  It has a mode where it can take in the mouse data
> > > and spit it out (translate) into Mouse System protocol.  It spits it out into a
> > > named FIFO called "/dev/gpmdata".  There are some mouse protocols that gpm
> > > understands that XFree86 can not, so gpm is useful in translating the unknown
> > > mouse movements into something XF68 knows.  In the case of bus mice, to use the
> > > mouse in both text console and X, gpm is pretty much required (something about
> > > the bus mouse only allowed to be opened once).
> > >
> > > To set gpm up as a repeater (the translation mode), create a named FIFO called
> > > "/dev/gpmdata" (need to be root):
> > >
> > > bash# mkfifo /dev/gpmdata
> > >
> > > This FIFO should be chown'd to the uid of the gpm that will run.  In most
> > > cases, it'll be root (by being exectued from an rc script):
> > >
> > > bash# chown root /dev/gpmdata
> > >
> > > Preferably, the FIFO should be chmod'd to 644, so that any random process won't
> > > mangle mouse data, and it can always be read.
> > >
> > > bash# chmod 644 /dev/gpmdata
> > >
> > > Alternatively, just "chmod 666 /dev/gpmdata" without chown'ing if you don't
> > > expect any rogue processes/users screwing around with the mouse data.
> > >
> > > In X, set it to use Mouse System (I think) protocol, using /dev/gpmdata as the
> > > device.
> > >
> > > In the rc script (or whenever else gpm is being started), gpm needs to be
> > > passed the "-R" (repeater) option.  On Red Hat (-based?) boxen, it's in
> > > /etc/rc.d/init.d/gpm.  On Debian boxen, /etc/init.d/gpm.
> > >
> > > Also, gpm would need to be configured to recognize the mouse first.  If
> > > the mouse works in text console, no need to fiddle with that.  Otherwise...
> > > umm... /etc/sysconfig/mouse in RH5.2, /etc/gpm.conf in Debian.
> > >
> > > All this is documented somewhere in one of the HOWTOs, but I can't recall which
> > > one.
> > >
> > > -Fred
> > >
> > > _______________________________________________
> > > Linux maillist  -  Linux@linux.ucla.edu
> > > http://linux.ucla.edu/mailman/listinfo/linux
> >
> >
> > _______________________________________________
> > Linux maillist  -  Linux@linux.ucla.edu
> > http://linux.ucla.edu/mailman/listinfo/linux
> --
> "If you would persuade, you must appeal to interest rather than intellect."
>                      - Benjamin Franklin -
>
> _______________________________________________
> Linux maillist  -  Linux@linux.ucla.edu
> http://linux.ucla.edu/mailman/listinfo/linux
发表于 2004-1-7 08:09:23 | 显示全部楼层

我的实践结果

我的做法:
mkinfo /dev/gpmdata
chown root /dev/gpmdata
chmod 644 /dev/gpmdata
在XF86Config中
Option    "rotocol"    "MouseSystems"
Option    "Device"      "/dev/gpmdata"
改gpm的起动命令为:
/usr/sbin/gpm -R msc -m /dev/mouse -t imps2
然后,能在退出X后使用gpm了,就是在X中不能使用滚轮了   
发表于 2004-1-7 09:45:15 | 显示全部楼层

还有[ZT],没来得及试

--------------------------------------------------------------------------------
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: tiny mouse howto - console gpm, X and mouse wheel

--------------------------------------------------------------------------------

To: mldeb@forevers.de (Steffen Evers)
Subject: Re: tiny mouse howto - console gpm, X and mouse wheel
From: timothy bauscher <q@foce.eiomail.com>
Date: Wed, 20 Mar 2002 15:18:36 -0500
Cc: debian-user@lists.debian.org

--------------------------------------------------------------------------------

> I have just seen that some people have problems with the combination
> of
> gpm, XFree86 and the mouse wheel support for X11.
>
> It has taken a while until I found out what to do.
>
> I have a cordless Logitech wheel mouse and now all works.
>
> gpm settings in /etc/gpm.conf:
> device=/dev/psaux
> responsiveness=
> repeat_type=raw
> type=imps2
> append=""

I just installed gpm after reading your setup.
My PS/2 mouse instantly left the screen, and
X would make a beep sound whenever i moved
the mouse. My settings were:

device: /dev/psaux
type: autops2
repeat type: m83

Those were the defaults provided by gpm, so i
just took them. I think that the repeat type and
type may be wrong though. If anyone here is using
gpm with a PS/2, please send me your settings.

> Mouse section in /etc/X11/XF86Config-4:
> Section "InputDevice"
>         Identifier  "Mouse0"
>         Driver      "mouse"
>         Option      "ZAxisMapping" "4 5"
>         Option      "rotocol" "IMPS/2"
>         Option      "Buttons"   "3"
>         Option      "Device" "/dev/gpmdata"
>         Option      "SampleRate" "60"
>         Option      "BaudRate" "1200"
> EndSection

I backed up my XF86Config-4 file first, then i
added the SampleRate, BaudRate, and device
you mention above. I did end up getting my old
mouse back, but i would like a second try at
getting this wheel to work. Perhaps i should
RTFM or something...

> The wheel did not work properly without the SampleRate and BaudRate
> settings.

(==timothy==)

"Live to learn. Learn to love. Love to live."




--------------------------------------------------------------------------------

Follow-Ups:
Re: tiny mouse howto - console gpm, X and mouse wheel
From: Andrew Agno <agno@AI.SRI.COM>
Re: tiny mouse howto - console gpm, X and mouse wheel
From: Steffen Evers <mldeb@forevers.de>
Re: tiny mouse howto - console gpm, X and mouse wheel
From: Dale Hair <dalehair1@attbi.com>
Prev by Date: SSMTP Problem with LF
Next by Date: First post
Previous by thread: tiny mouse howto - console gpm, X and mouse wheel
Next by thread: Re: tiny mouse howto - console gpm, X and mouse wheel
Index(es):
Date
Thread
发表于 2004-1-7 09:47:51 | 显示全部楼层
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表