Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Feb 1997 12:44:52 +0900
From:      Kazutaka YOKOTA <yokota@zodiac.mech.utsunomiya-u.ac.jp>
To:        gurney_j@resnet.uoregon.edu
Cc:        terry@lambert.org, freebsd-current@freebsd.org, yokota@zodiac.mech.utsunomiya-u.ac.jp
Subject:   Re: moused on notebooks... 
Message-ID:  <199702130344.MAA23897@zodiac.mech.utsunomiya-u.ac.jp>
In-Reply-To: Your message of "Wed, 12 Feb 1997 19:06:21 MST." <199702130206.TAA01310@phaeton.artisoft.com> 
References:  <199702130206.TAA01310@phaeton.artisoft.com> 

next in thread | previous in thread | raw e-mail | index | archive | help
>> right now I'm running moused on my notebook w/ a ps/2 mouse...  if I ever
>> have the mouse detacted when the notebook is up and running I will loose
>> the mouse until I restart moused...  
>> 
>> would anybody object to possibly added a signal handler to moused for
>> SIGHUP to force it to reopen the mouse device?  comments?
>
>In the situation you describe, the SIGHUP would arive when you
>unplugged the mouse, not when you plugged it in.  You want it to
>be opened *after* you plug it in.

For the serial mouse, catching SIGHUP is possible. (But, it will be
useless as Terry Lambert points out) But, the PS/2 mouse device (psm)
doesn't generate SIGHUP; the PS/2 mouse interface doesn't have a
mechanism to detect plugging/unplugging action, AFAIK.

In fact, plugging/unplugging the PS/2 mouse, or the keyboard, while
your system's power is on is really, really a bad idea. Your keyboard
controller can easily be fried by the noise caused at the connector.
I know a couple of poor guys who learned this in a hard way...

Maybe some notebook/laptop computers may have an safe-guarded
circuitry and allow this sort of action. I strongly recommend you to
consult the manual of your notebook and find if it is really OK to
attach/detach the PS/2 mouse on the fly.

Kazu



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199702130344.MAA23897>