XFree mouse driver

Hello,

I’m trying to use xf86cfg or xf86config to set up mouse, but I don’t know what mouse driver to specify. I can use /dev/devi/mouse, but it seems not working. What should I use?

Darius

The XFree86’s mouse driver (serial, ps2, etc) is not being used. It relies on the OS for the mouse handling. There is a special mouse category in XFree 86 called OSMouse. If you run “XFree86 -configure” to generate the config file, you should be able to see “OSMouse” is automatically selected.

xf86cfg (GUI) and xf86config (text mode) tools are being depreciated. You should really use “XFree86 -configure” instead.

BTW, to start the QNX OS mouse driver, you can run, eg: for PS2 mouse,

/usr/photon/bin/devi-hirun -Pr ps2 mousedev

(you may need to be root to start the mouse driver).

Hello,

I have already used that. startx starts in a black screen and nobody helps except reboot. xf86cfg with this mouse device well but on exit shell stops responding. Seems /usr/photon/bin/devi-hirun -Pr ps mousedev is not working. I don’t know what to do.

Darius

Are you saying your mouse works fine in xf86cfg but not for “startx”?

If so, your mouse driver is actually ok and you must be having other problems. Post your XF86Config file in /etc/X11

If not, post output of “/usr/photon/bin/inputtrap -v” and see what kind of mouse you have.

Hello

Yes, exactly. xf86cfg works well with /dev/devi/mouse0, but X doesn’t. Computer simply hangs.

What about XF86Config file? Which of them is using X? There are two: one /etc/X11, another /usr/X11R6/lib/X11/XF86Config. Both are the same, but xf86cfg suggests to write to /usr/X11R6/lib/X11/XF86Config. Here is my XF86Config:

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 “extmod”
Load “glx”
Load “dbe”
Load “record”
Load “xtrap”
Load “speedo”
Load “type1”
EndSection

Section “InputDevice”
Identifier “Keyboard0”
Driver “keyboard”
EndSection

Section “InputDevice”
Identifier “Mouse0”
Driver “mouse”
Option “Protocol” “PS/2”
Option “Device” “/dev/devi/mouse0”
EndSection

Section “Monitor”

#DisplaySize	  320   240	# mm
Identifier   "Monitor0"
VendorName   "PTS"
ModelName    "304"
Option	    "DPMS"

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     "SWcursor"           	# [<bool>]
    #Option     "HWcursor"           	# [<bool>]
    #Option     "NoAccel"            	# [<bool>]
    #Option     "ShowCache"          	# [<bool>]
    #Option     "ShadowFB"           	# [<bool>]
    #Option     "UseFBDev"           	# [<bool>]
    #Option     "Rotate"             	# [<str>]
    #Option     "VideoKey"           	# <i>
    #Option     "FlatPanel"          	# [<bool>]
    #Option     "FPDither"           	# [<bool>]
    #Option     "CrtcNumber"         	# <i>
Identifier  "Card0"
Driver      "nv"
VendorName  "nVidia Corporation"
BoardName   "NV11 [GeForce2 MX/MX 400]"
BusID       "PCI:1:0:0"

EndSection

Section “Screen”
Identifier “Screen0”
Device “Card0”
Monitor “Monitor0”
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

And there is output for /usr/photon/bin/inputtrap -v:

Probing: keyboard
/dev/kbd exists, using…
Probing: ps2
Found ps2 mouse. Assuming interrupt 12.
Probing: sermouse
Attempting PnP comm enumeration on /dev/ser1
comm enumeration failed on /dev/ser1
Attempting PnP comm enumeration on /dev/ser2
comm enumeration failed on /dev/ser2

Thats all. And one more thing: thank you for helping me.

Best regards,
Darius

Hello,

Now it seems everything is working ok. If mouse protocol is PS2 then mouse acts like a mad - only one touch and it runs all over the screen. OSMOUSE protocol seems to work just fine. But still I have some questions. First of all, which config file X is using. Second - how to set more colors and resolution? My video card is supported (GeFoirce2 MX400), but I can see only 16 colors, resolutions seems to be changing don’t know if refrech rate is changing. How to config all video details? XF86Config file contains no such detailed info.

Best regards,
Darius

Your “inputtrap -v” did show you have a PS2 mouse, so you were right in starting the OS mouse driver using:
/usr/photon/bin/devi-hirun -Pr ps2 mousedev
The fact that the mouse works fine in “xf86cfg” confirms this.

By looking at your XF86Config file:

  1. the mouse type should be OSMouse, as you already find out.
  2. in the “Monitor” section, you probably want to add the horizontal and vertical sync rate of your monitor, eg:
    HorizSync 48-65
    VertRefresh 60-75
  3. the “Screen” section is where you can define the “resolution” and “color depth”. Here is a copy from mine, just to give you an idea:

Section “Screen”
Identifier “Screen0”
Device “Card0”
Monitor “Monitor0”
DefaultDepth 24
SubSection “Display”
Depth 24
Modes “1024x768”
EndSubSection
EndSection

To answer you last question as which “XF86Config” is being used: check the man page of XF86Config. Here is the online version:

xfree86.org/4.3.0/XF86Config.5.html

Hello,

Thank you very much. You has helped me a lot. I have just one question and maybe its not about QNX or XFree86. At any monitor resolution right corner of the monitor is some kind of damaged: all text and graphics at the right corner is narrow. The same is with photon. How do you think what is that? Maybe GeForce drivers?
Thanks.

Best regards,
Darius

That is normal result of mis-timed monitor settings. From memory, when I played with one of the early Slackware installs, the mode timings were all placed at the start of XF86config file.

Try increasing the HTotal figure for your prefered graphics mode by say 10% more than it’s current setting.

Hello,

Do you mean to use 1126x768 instead of 1024x768 or to increase horizontal refresh rate of monitor?

alpha

HTotal is not the resolution. Sometimes resolution can make difference but only incidently. Actually, increasing HTotal decreases the scan rate. Did you even look at the settings?

Hello,

Yes, I have looked, but there is no such thing as “HTimings hdisp hsyncstart hsyncend htotal” in my XF86Config file, so I have no idea what these timing must be. Any ideas are wellcome. Thanks for helping me.

Best regards,
Darius

I guess things have changed since those days.

Hello

So what you suggest me to do? How to set these timings? I am experiencing the same problem with photon as well. Please help.

Best regards,
Darius

not really. they are still there. it is just the default XF86Config file doesn’t have it and XFree will just use some default values. you can definitely add those keywords in there if you find the default stuff doesn’t fit your need. Read the manual page at xfree86.org/4.3.0/XF86Config.5.html In particular, the Monitor Section. BTW, this is really beyond QNX and people on the XFree86 mailing list should be in the better position to help.