Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Jul 2001 10:40:25 -0400
From:      "Sung N. Cho" <sucho2@vt.edu>
To:        prophetx2@home.com
Cc:        "Brandon S. Allbery KF8NH" <allbery@ece.cmu.edu>, stable@FreeBSD.ORG
Subject:   Re: Has anyone got their USB mouse working on FreeBSD 4.x?
Message-ID:  <3B544E59.4E2E0089@vt.edu>
References:  <3B538F90.BE7A8888@vt.edu> <68650000.995331701@vpn74.ece.cmu.edu> <3B539698.BDEC79CD@vt.edu> <01071701062400.49410@core.core-slave.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Dennis Cheung wrote:

> On Monday 16 July 2001 21:36, Sung N. Cho wrote:
> > "Brandon S. Allbery KF8NH" wrote:
> > > On Monday, July 16, 2001 21:06:24 -0400, "Sung N. Cho" <sucho2@vt.edu>
> > > wrote:
> > > +-----
> > >
> > > | Has anyone got their USB mouse working on their FreeBSD system?  I
> > >
> > > +--->8
> > >
> > > I plugged the USB mouse from a Sun Blade 100 into my 4.3-RELEASE laptop
> > > to see what would happen, and it "just worked".
> > >
> > > | detects the mouse "Kensington MIAB mouse" but I'm not seeing any mouse
> > > | cursor on console nor do I get any response when I try to use it under
> > > | X.  Only PS/2 mouse is working at the moment.
> > >
> > > +--->8
> > >
> > > If you're doing this under X, you probably want to make sure you're using
> > > sysmouse; if it's set to use the PS/2 mouse directly then it will only
> > > use that and never notice the USB mouse.  Using sysmouse XFree86 happily
> > > used both the onboard PS/2 trackpad and the USB mouse while the latter
> > > was plugged in.
> > >
> > > --
> > > brandon s. allbery  [os/2][linux][solaris][freebsd]
> > > allbery@kf8nh.apk.net system administrator   [JAPH][WAY too many hats]
> > >     allbery@ece.cmu.edu electrical and computer engineering
> > >                     KF8NH carnegie mellon university     [linux: proof of
> > > the million monkeys theory]
> > >
> > > To Unsubscribe: send mail to majordomo@FreeBSD.org
> > > with "unsubscribe freebsd-stable" in the body of the message
> >
> > Yes, I did that.
> >
> > But, that doesn't seem to work.  I get device busy, cab't open error!
> >
> > in /etc/rc.conf  I have usbd_enable="YES"
> > in /etc/X11/XF86Config, for the pointer section, I have:
> >
> > Section "InputDevice"
> >         Identifier    "Mouse0"
> >         Driver        "mouse"
> >         Option        "Protocol"  "auto"
> >         Option        "Device"  "/dev/sysmouse"
> > EndSection
> >
> > This didn't work, so I tried now:
> >
> > Section "InputDevice"
> >         Identifier    "Mouse0"
> >         Driver        "mouse"
> >         Option        "Protocol"  "auto"
> >         Option        "Device"  "/dev/ums0"
> > EndSection
> >
> > This doesn't work either!
> >
> > At the console, I tested,
> > #moused -p /dev/ums0 -t auto
> > and this gives unable to open device, device busy signal!   I've disabled
> > both serial ports and parallel ports so there are enough irqs available for
> > USB mouse to use.  FreeBSD claims Kensington MIAB optical mouse is
> > supported.
> >
> >
> >
> > Sung N. Cho,
> > Dept. of Physics,
> > Virginia Polytechnic Institute & State University.
> >
> >
> >
> >
> > To Unsubscribe: send mail to majordomo@FreeBSD.org
> > with "unsubscribe freebsd-stable" in the body of the message
>
> Edit /etc/rc.conf and add the following lines:
>     moused_enable="YES"
>     moused_type="auto"
>     moused_port="/dev/ums0"
>     moused_flags=""
>     usbd_enable="YES"
>     usbd_flags=""
> also make sure you have this in your kernel conf
>
>     controller        uhci0
>     controller        ohci0
>     controller        usb0
>     device            ums0
> when you boot up type vidcontrol -m on.
>
> That did it for me when i couldn't figure out was wrong.  Does your mouse
> work at all in /stand/sysinstall after you edited the /etc/rc.conf like you
> are supposed to?  I have a logitech usb mouse and it works fine as well as a
> razor boomslang usb mouse.  Good luck.
>
> -Dennis

Hi, unfortunately, I did all those but the mouse still don't work!  At the
initial installation (fresh install from scratch), at one point the system asks
whether you have a USB mouse attached to the system or not, I answer "YES".  I
don't see any mouse cursor.  Maybe it will show when I boot.  Well, I booted and
I get...... "Device busy" signal.  Also, I believe the GENERIC kernel already
has USB compiled in.  I don't think it's the mouse, but FreeBSD since this mouse
works flawlessly under both Windows and Linux (Redhat 7.1).  I am thinking that
FreeBSD still has lack of support for Laptop computers.

Here's how my CUSTOM kernel configuration looks:  I don't use mouse in syscons,
so I disabled it.  (Also, since the GENERIC kernel doesn't seem to solve the
problem of getting USB mouse to work!)

-----------------------------------
#
# SNCHOKERNEL -- Sung's custom kernel configuration file for FreeBSD/i386
#

machine        i386
ident  SNCHOKERNEL
maxusers 32

makeoptions CONF_CFLAGS=-fno-builtin  # Don't allow use of memcmp, etc.
makeoptions     CONF_COPTFLAGS="-O -pipe" # Optimize the kernel compilation


###########################################################
# CPU OPTIONS

cpu  I686_CPU  # Aka Pentium Pro(tm)
options  CPU_FASTER_5X86_FPU # Enable faster FPU exception handler.


###########################################################
# COMPATIBILITY OPTIONS

options  COMPAT_43
options  USER_LDT # Allow user-level control of i386 ldt

# System V shared memory and tunable parameters
options  SYSVSHM  # Include support for shared memory
options  SHMMAXPGS=1025 # Max amount of shared memory pages (4k on i386)
options  SHMALL=1025 # Max amount of shared memory (bytes)
options  SHMMAX="(SHMMAXPGS*PAGE_SIZE+1)" # Max shared memory segment size
(bytes)
options  SHMMIN=2 # Min shared memory segment size (bytes)
options  SHMMNI=33 # Max number of shared memory identifiers
options  SHMSEG=9 # Max shared memory segments per process

# System V semaphores and tunable parameters
options  SYSVSEM  # Include support for semaphores
options  SEMMAP=31 # Amount of entries in semaphore map
options  SEMMNI=11 # Number of semaphore identifiers in the system
options  SEMMNS=61 # Number of semaphores in the system
options  SEMMNU=31 # Number of undo structures in the system
options  SEMMSL=61 # Max number of semaphores per id
options  SEMOPM=101 # Max number of operations per semop call
options  SEMUME=11 # Max number of undo entries per process

# System V message queues and tunable parameters
options  SYSVMSG  # Include support for message queues
options  MSGMNB=2049 # Max characters per message queue
options  MSGMNI=41 # Max number of message queue identifiers
options  MSGSEG=2049 # Max number of message segments in the system
options  MSGSSZ=16 # Size of a message segment MUST be power of 2
options  MSGTQL=41 # Max amount of messages in the system


###########################################################
# DEBUGGING OPTIONS

options  KTRACE   # Kernel tracing
options  UCONSOLE
options  USERCONFIG  # Boot -c editor
options  INTRO_USERCONFIG # Imply -c and show intro screen
options  VISUAL_USERCONFIG # Visual boot -c editor


###########################################################
# NETWORKING OPTIONS

#
# Protocol families:
#

options  INET   # Internet communications protocols
options  INET6   # IPv6 communications protocols
options  IPSEC   # IP security
options  IPSEC_ESP  # IP security (crypto; define w/ IPSEC)

#
# Network interfaces:
#

pseudo-device ether   # Generic Ethernet
pseudo-device loop   # Network loopback device
pseudo-device bpf   # Berkeley packet filter

# for IPv6
pseudo-device gif 4  # IPv6 and IPv4 tunneling
pseudo-device faith 1  # For IPv6 and IPv4 translation
pseudo-device stf   # 6to4 IPv6 over IPv4 encapsulation

#
# Internet family options:
#

options  MROUTING  # Multicast routing
#options  IPFIREWALL  # Firewall
#options  IPFIREWALL_VERBOSE # Print information about dropped packets
#options  IPFIREWALL_FORWARD # Enable transparent proxy support
#options  IPFIREWALL_VERBOSE_LIMIT=100 # Limit verbosity
#options  IPFIREWALL_DEFAULT_TO_ACCEPT # Allow everything by default
#options  IPV6FIREWALL  # Firewall for IPv6
#options  IPV6FIREWALL_VERBOSE
#options  IPV6FIREWALL_VERBOSE_LIMIT=100
#options  IPV6FIREWALL_DEFAULT_TO_ACCEPT
#options  IPDIVERT  # Divert sockets
#options  IPFILTER  # Ipfilter support
#options  IPFILTER_LOG  # Ipfilter logging
#options IPFILTER_DEFAULT_BLOCK # Block all packets by default
#options  IPSTEALTH  # Support for stealth forwarding
#options  TCPDEBUG

options  ICMP_BANDLIM

#options  DUMMYNET  # Requires firewall
#options  BRIDGE   # Requires firewall


###########################################################
# FILESYSTEM OPTIONS

options  FFS   # Fast filesystem
options  FFS_ROOT  # FFS usable as root device
options  SOFTUPDATES  # Enable file reliability/performance
options  NSWAPDEV=1  # Allow this many swap disks
options  QUOTA   # Enable disk quotas


###########################################################
# POSIX P1003.1B

# Real time extensions added in the 1993 Posix
# P1003_1B: Infrastructure
# _KPOSIX_PRIORITY_SCHEDULING: Build in _POSIX_PRIORITY_SCHEDULING
# _KPOSIX_VERSION:             Version kernel is built for

options  P1003_1B
options  _KPOSIX_PRIORITY_SCHEDULING
options  _KPOSIX_VERSION=199309L


###########################################################
# MISCELLANEOUS DEVICES AND OPTIONS

pseudo-device pty   # Pseudo ttys


###########################################################
# HARDWARE DEVICE CONFIGURATION

# ISA and EISA devices:
device  isa


# The keyboard controller; it controls the keyboard and the PS/2 mouse.
device  atkbdc0 at isa? port IO_KBD
device  atkbd0 at atkbdc? irq 1 # The AT keyboard
options  ATKBD_DFLT_KEYMAP # Specify the built-in keymap
makeoptions ATKBD_DFLT_KEYMAP="us.iso"
options  KBD_INSTALL_CDEV # Install a CDEV entry in /dev

# PS/2 mouse
device  psm0 at atkbdc? irq 12
options  PSM_HOOKRESUME  # Hook the system resume event
options  PSM_RESETAFTERSUSPEND # Reset the device at the resume event

# The video card driver.
device  vga0 at isa?
options  VGA_NO_FONT_LOADING # Don't save/load font
options  VGA_NO_MODE_CHANGE # Don't change video modes

# Splash screen at start up!  Screen savers require this too.
pseudo-device splash

# The syscons console driver (sco color console compatible).
device  sc0 at isa?
options  MAXCONS=16  # Number of virtual consoles
options  SC_NO_CUTPASTE
options  SC_NO_FONT_LOADING
options  SC_NO_HISTORY
options  SC_NO_SYSMOUSE

# The Numeric Processing eXtension driver (Floating point processor)
device  npx0 at nexus? port IO_NPX flags 0x0 irq 13

# ATA and ATAPI devices.
device  ata
device  atadisk   # ATA disk drives
device  atapicd   # ATAPI CDROM drives

# Standard floppy disk controllers: `fdc' and `fd'
device  fdc0 at isa? port IO_FD1 irq 6 drq 2
device  fd0 at fdc0 drive 0

# Network interfaces (PCI/ISA/PCMCIA Ethernet NICs):
device ed

# PCI devices:
device  pci

# PCCARD/PCMCIA
device  pcic0 at isa?
device  card
options  PCIC_RESUME_RESET # Reset after resume

# Power management support (see LINT for more options)
device  apm0    at nexus? flags 0x20 # Advanced Power Management
----------------------------------------------------------------------------------------------



Please note that I'm using USB system as a module since I sometimes attach and
disattach them frequently.  To enable the USB system and soundcard support, I am
loading the mosules from /boot/loader.conf.  Here's what my loader.conf looks
like:

------------------------------------------------------------------
userconfig_script_load="YES"
autoboot_delay="2"  # Delay in seconds before autobooting
snd_maestro_load="YES"  # ess maestro-2 pci (my sound card)
usb_load="YES"   # USB subsystem
ugen_load="YES"   # USB generic device, if all else fails ...
uhid_load="YES"   # Human Interface Devices
ums_load="YES"   # Mouse
agp_load="YES"   # agp module
------------------------------------------------------------------

For my rc.conf file, it looks:

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

# -- sysinstall generated deltas -- #
# Created: Mon Jul 16 14:33:52 2001
# Enable network daemons for user convenience.
# This file now contains just the overrides from /etc/defaults/rc.conf
# please make all changes to this file.
defaultrouter="198.82.153.65"
hostname="vt.edu"
ifconfig_ed1="inet 198.82.153.87  netmask 255.255.255.192"
inetd_enable="YES"
ipv6_enable="YES"
kern_securelevel_enable="NO"
keyrate="fast"
linux_enable="YES"
pccard_enable="YES"
pccard_beep="0"
pccard_ifconfig="inet 198.82.153.87  netmask 255.255.255.192"
pccard_mem="DEFAULT"
pccardd_flags=" -i 3"
saver="daemon"
sendmail_enable="YES"
sshd_enable="YES"
usbd_enable="YES"
apm_enable="YES"
---------------------------------------------------------------------


Here's what my /etc/X11/XF86Config files looks like:

---------------------------------------------------------------------
Section "ServerLayout"
 Identifier     "XFree86 Configured"
 Screen      0  "Screen0" 0 0
 InputDevice    "Mouse0" "CorePointer"
 InputDevice    "Keyboard0" "CoreKeyboard"
EndSection

Section "Files"
 RgbPath      "/usr/X11R6/lib/X11/rgb"
 ModulePath   "/usr/X11R6/lib/modules"
 FontPath     "/usr/X11R6/lib/X11/fonts/misc/"
 FontPath     "/usr/X11R6/lib/X11/fonts/Speedo/"
 FontPath     "/usr/X11R6/lib/X11/fonts/Type1/"
 FontPath     "/usr/X11R6/lib/X11/fonts/CID/"
 FontPath     "/usr/X11R6/lib/X11/fonts/75dpi/"
 FontPath     "/usr/X11R6/lib/X11/fonts/100dpi/"
EndSection

Section "Module"
 Load  "dbe"
# Load  "dri"
 Load  "extmod"
# Load  "glx"
 Load  "pex5"
 Load  "record"
 Load  "xie"
 Load  "type1"
 Load  "freetype"
EndSection

Section "InputDevice"
 Identifier  "Keyboard0"
 Driver      "keyboard"
EndSection

Section "InputDevice"
 Identifier  "Mouse0"
 Driver      "mouse"
 Option      "Protocol" "auto"
 Option      "Device" "/dev/ums0"
 Option     "Buttons" "3"
 Option      "ZAxisMapping" "4 5"
EndSection
Section "Monitor"
 Identifier   "Monitor0"
 VendorName   "Monitor Vendor"
 ModelName    "Monitor Model"
EndSection

Section "Device"
 ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        Option     "accel" "True"               # [<bool>]
        #Option     "crt_screen"          # [<bool>]
        #Option     "composite_sync"      # [<bool>]
        Option     "hw_cursor" "True"           # [<bool>]
        Option     "linear" "Trued"             # [<bool>]
        Option     "mmio_cache" "True"          # [<bool>]
        #Option     "probe_clocks"        # [<bool>]
        #Option     "reference_clock"     # <freq>
        Option     "shadow_fb" "True"           # [<bool>]
        #Option     "sw_cursor"           # [<bool>]
 Identifier  "Card0"
 Driver      "ati"
 VendorName  "ATI"
 BoardName   "Mach64 LB"
 ChipSet     "ati"
 ChipId      0x4c42
 ChipRev     0xdc
 VideoRam    8192
 BusID       "PCI:1:0:0"
EndSection

Section "Screen"
 Identifier "Screen0"
 Device     "Card0"
 Monitor    "Monitor0"
 DefaultColorDepth 16
 SubSection "Display"
  Depth     1
 EndSubSection
 SubSection "Display"
  Depth     4
 EndSubSection
 SubSection "Display"
  Depth     8
 EndSubSection
 SubSection "Display"
  Depth     15
 EndSubSection
 SubSection "Display"
  Depth     16
 EndSubSection
 SubSection "Display"
  Depth     24
 EndSubSection
EndSection
-------------------------------------------------------------


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3B544E59.4E2E0089>