Meego Wiki
Views
From MeeGo wiki
Jump to: navigation, search

This is the device in question:

Contents

Info

http://www.3dconnexion.com/products/spacenavigator.html

More info

http://www.3dconnexion.com/service/software-developer.html is a good source of info. Windows is better documented than Linux.

Linux/MeeGo support

There are basically three options (mutually exclusive) to use this device under Linux/MeeGo:

  1. Use 3Dconnexion drivers and libraries (SDK available after registering on their website)
  2. Use open-source spacenav library/daemon <-- this seems to be a very good/stable option
  3. Use MeeGo native drivers (in which case the mouse is no more than a standard 2D mouse with 2 buttons)

spacenavd

http://spacenav.sourceforge.net/

tar xvf spacenavd-0.5.tar.gz
cd  spacenavd-0.5
./configure
make

This creates a socket-based server you app can connect to. For examples, please check the example included in the SDK: http://sourceforge.net/projects/spacenav/files/spacenav%20library%20%28SDK%29/

MeeGo native drivers

As soon as you connect this device to your MeeGo system, the native driver (evdev) will pick it up and add it to the list of pointer device (i.e. a mouse). You can check this using xinput as follows:

Install xinput first (not installed by default)

zypper in xorg-x11-utils-xinput (in MeeGo 1.2, slightly different name in MeeGo 1.0)
xinput --list
 Virtual core pointer                          id=2    [master pointer  (3)]
   ? Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
   ? CHESEN USB Keyboard                       id=9    [slave  pointer  (2)]
   ? 3Dconnexion Space Navigator               id=10   [slave  pointer  (2)]
   ? Dell Dell USB Mouse                       id=11   [slave  pointer  (2)]
   ? EVTouch TouchScreen                       id=12   [slave  pointer  (2)]
 Virtual core keyboard                         id=3    [master keyboard (2)]
   ? Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
   ? Video Bus                                 id=6    [slave  keyboard (3)]
   ? Power Button                              id=7    [slave  keyboard (3)]
   ? CHESEN USB Keyboard                       id=8    [slave  keyboard (3)]

At that point, the mouse is essentially functional but extremely sensitive. To correct this, you can play with the device properties named Device Accel Constant Deceleration (237) and/or Device Accel Adaptive Deceleration (239). I've had some good luck setting property '237' between 20 and 50.

xinput --list-props 10
Device '3Dconnexion Space Navigator':
       Device Enabled (118):   1
       Device Accel Profile (236):     0
       Device Accel Constant Deceleration (237):       1.000000
       Device Accel Adaptive Deceleration (239):       1.000000
       Device Accel Velocity Scaling (240):    10.000000
       Evdev Reopen Attempts (234):    10
       Evdev Axis Inversion (241):     0, 0
       Evdev Axes Swap (243):  0
       Axis Labels (244):      "Rel X" (126), "Rel Y" (127), "Rel Z" (256), "Rel Rotary X" (257), "Rel Rotary Y" (258), "Rel Rotary Z" (259)
       Button Labels (245):    "Button 0" (254), "Button 1" (255), "Button Unknown" (235), "Button Wheel Up" (122), "Button Wheel Down" (123)
       Evdev Middle Button Emulation (246):    2
       Evdev Middle Button Timeout (247):      50
       Evdev Wheel Emulation (248):    0
       Evdev Wheel Emulation Axes (249):       0, 0, 4, 5
       Evdev Wheel Emulation Inertia (250):    10
       Evdev Wheel Emulation Timeout (251):    200
       Evdev Wheel Emulation Button (252):     4
       Evdev Drag Lock Buttons (253):  0

xinput --set-prop 10 237 20

In MeeGo 1.2:

  • Create a new file called 3Dconnexion.conf in /etc/X11/xorg.conf.d/ (i.e. no need to use a script anymore)
  • Copy and past the following text in this new file and restart X.
 Section "InputClass"
         Identifier "evdev 3Dconnexion"
         MatchProduct "3Dconnexion|Space Navigator"
         Driver "evdev"
         Option "ConstantDeceleration" "30"
 EndSection

Note: something *very* similar should also work in MeeGo 1.0 by adding the same section in /etc/X11/xorg.conf but I have not tested it yet. In the meantime an easy work around is to add this line to a script file that runs when system boots up (i.e. /usr/bin/startivi):

 xinput set-prop "3Dconnexion Space Navigator" 237 20
Personal tools