Added some examples on deadzones

This commit is contained in:
Ingo Ruhnke 2011-01-29 02:29:25 +01:00
parent 66576abb43
commit 330e62dacc
3 changed files with 67 additions and 33 deletions

54
TODO
View file

@ -42,6 +42,8 @@ $ dput my-ppa ../xboxdrv_0.7.1-1~lucid1_source.changes
Stuff to do before 0.7.1 release:
=================================
* make more use of percentance values (in deadzone filter for example)
* add option to increase libusb debug level
* document --device-name TYPE.SLOT=NAME, --name
@ -50,20 +52,21 @@ Stuff to do before 0.7.1 release:
* fix device name of mimic_xpad
* boost::lexical_cast<> error messages are useless, make some better ones
* allow multiple controllers in non-daemon mode
* couldn't convert 'XK_Page_Up' to enum, not a member of X11Keysym
currenty code can't handle multple names for a single key
* document match rules
* improve output in daemon mode, when --quiet is not given print the number of allocated controller slots
* improve output in daemon mode, when --quiet is not given print the
number of allocated controller slots
* add introspection to filters and modifier stack
* [ERROR] XboxdrvDaemon::process_match(): no free controller slot found, controller will be ignored
- should include info about what controller is ignored
* print controller type/name in daemon (little tricky as that is only
known after opening the USB connection)
* update debian package description
* valgrind before release
@ -89,10 +92,22 @@ Stuff to do before 0.7.1 release:
on configuration changes, controller plug-ins, etc. (notifiy area as example)
- also supply useful information as argument
* improve output on which uinput devices are created (even with udev
there doesn't seem to be a bullet proof way to detect what gets
created)
* do modifier/filter dump when --verbose is given, make verbose
overall more useful
Stuff to do before 0.7.2 release:
=================================
* boost::lexical_cast<> error messages are useless, make some better ones
* couldn't convert 'XK_Page_Up' to enum, not a member of X11Keysym
currenty code can't handle multple names for a single key
* --match again sysname could make sense, seems somewhat constant:
"5-2" Xbox1 controller results in "5-2.1", due to being really two
devices, would help to now how exactly those are formed
@ -105,9 +120,6 @@ Stuff to do before 0.7.2 release:
* extend usbid match rule to bcd device
* cleanup device_id, don't manually do (slot<<16) | devid (only an
issue in force feedback code)
* get rid of all std::cout stuff when using detached daemon, redirect
log output to a file somewhere else:
@ -122,16 +134,14 @@ Stuff to do before 0.7.3 release:
* turn EnumBox into singleton
* allow EnumBox to have multiple names per values per key
* allow --modifier help, --ui-buttonmap X2^help
* move XBOX_BTN_UNKNOWN behind XBOX_BTN_MAX, so iteration can start
from 0 instead of 1, also fix incorrect iterations all over the
place -> doesn't work as some code uses XBOX_BTN_UNKNOWN as 'no
button is pressed'
* improve output on which uinput devices are created (even with udev
there doesn't seem to be a bullet proof way to detect what gets
created)
* move XBOX_BTN_UNKNOWN behind XBOX_BTN_MAX (or make it -1), so
iteration can start from 0 instead of 1, also fix incorrect
iterations all over the place -> doesn't work as some code uses
XBOX_BTN_UNKNOWN as 'no button is pressed'
* document significant patches in AUTHORS
@ -143,24 +153,18 @@ Stuff to do before 0.7.3 release:
1 hal daemon from Thomas Debouverie <debouverie_thomas@yahoo.fr>
1 Implemented --ui-buttonmap A=BTN_A@{device_id} ??!?!?
* do modifier/filter dump when --verbose is given, make verbose
overall more useful
* need to hide/disable the toggle button from the UIButtonmap
- maybe implement some full post-parsing option verification to
check for conflicts and necessary modifications?
- Options::finish() to do final things?
* print controller type/name in daemon (little tricky as that is only
known after opening the USB connection)
Stuff to do before 0.7.x release:
=================================
* -R, --rumble-test is broken for FirestormDualController (has no analog triggers)
* add ABS support to macros (need to deal with min/max)
* add ABS support to macros events (need to deal with min/max)
* Playstation 3 controller support
- http://www.pabr.org/sixlinux/sixlinux.en.html
@ -206,8 +210,6 @@ Stuff to do before 0.7.x release:
* get rid of set_button()/get_button(), turn the message objects into full classes
* document common problems, such as lack of deadzone handling in games
* make chatpad configurable:
--ui-chatpad a=KEY_A,green+a=SHIFT_X+KEY_B,...

View file

@ -5,7 +5,7 @@
\\$2 \(la\\$1\(ra\\$3
..
.if \n(.g .mso www.tmac
.TH "xboxdrv " 1 2010-05-05 0.7.0 "User Commands"
.TH "xboxdrv " 1 2010-05-05 0.7.1 "User Commands"
.SH NAME
xboxdrv
\- A Xbox/Xbox360 gamepad driver that works in userspace
@ -983,10 +983,8 @@ by the X11 keymap and will often not report what you
expect in case you use a keymap that is different then
your keyboard (i.e. dvorak on a qwerty keyboard).
A full list of X11 keysyms is available at
\*(T<\fI/usr/include/X11/keysymdef.h\fR\*(T>, note that you can only use those that
are reachable by your current keymap. Keysyms that are reachable via
multiple keycodes might break the mapping from keysym to evdev code.
A full list of valid X11 keysyms can be optained
with \*(T<\fB\-\-help\-x11keysym\fR\*(T>.
For joystick buttons there is in addition to the \fBBTN_JOYSTICK\fR, \fBBTN_X\fR,
etc. macros the special name \fBJS_$NUM\fR, which sets the given button to
@ -1493,7 +1491,24 @@ change the handling into buttons via
the \*(T<\fB\-\-trigger\-as\-button\fR\*(T> option:
.PP
.nf
\*(T<$ xboxdrv \-\-trigger\-as\-button \-s \*(T>
\*(T<$ xboxdrv \-\-trigger\-as\-button\*(T>
.fi
.SS "CONFIGURE A DEADZONE"
Many gamepads don't center exactly at zero, but at random
values around it. This 'noise' can confuse some games and is
thus be best filtered out, this can be accomplished with:
.PP
.nf
\*(T<$ xboxdrv \-\-deadzone 25%\*(T>
.fi
.PP
The percentance is the amount of noise that will get filtered
out, you can also give raw device values if you leave out the
% sign. If you want to have a deadzone only on a specific axis
you have to use axis filter:
.PP
.nf
\*(T<$ xboxdrv \-\-buttonmap X1^deadzone:15000\*(T>
.fi
.SS "KEYBOARD EMULATION"
The following configuration will cause xboxdrv to emulate a

View file

@ -2139,7 +2139,24 @@ $ modprobe joydev]]></programlisting>
the <option>--trigger-as-button</option> option:
</para>
<programlisting><![CDATA[$ xboxdrv --trigger-as-button -s ]]></programlisting>
<programlisting><![CDATA[$ xboxdrv --trigger-as-button]]></programlisting>
</refsect2>
<refsect2>
<title>Configure a deadzone</title>
<para>
Many gamepads don't center exactly at zero, but at random
values around it. This 'noise' can confuse some games and is
thus be best filtered out, this can be accomplished with:
</para>
<programlisting><![CDATA[$ xboxdrv --deadzone 25%]]></programlisting>
<para>
The percentance is the amount of noise that will get filtered
out, you can also give raw device values if you leave out the
% sign. If you want to have a deadzone only on a specific axis
you have to use axis filter:
</para>
<programlisting><![CDATA[$ xboxdrv --buttonmap X1^deadzone:15000]]></programlisting>
</refsect2>
<refsect2>