Commit Graph

46 Commits

Author SHA1 Message Date
rdb 986b803e71 device: recognize digitizers and pressure axis as well in evdev
Note that the Y axis is still inverted compared to on Windows; we need to decide what convention to follow here.
2019-12-17 22:56:26 +01:00
rdb 750afbb188 device: Linux fixes for Trust GXT 24 and a few other cheap gamepads
Fixes #576
2019-05-12 20:34:19 +02:00
Sebastian Hoffmann 16c3ca5c87 device: Fix swapped axes on right stick for Jess Colour Rumble Pad
Closes #639
2019-05-01 17:19:18 +02:00
rdb 3875cc8259 device: add proper mapping for 8bitdo N30 Pro Controller on Linux 2019-02-07 22:28:04 +01:00
rdb f8d7941fe8 device: fix a bad axis mapping on Linux 2019-02-06 22:03:44 +01:00
rdb c365beaf11 device: hide Steam Controller on Linux while Steam is running
When Steam runs, it mutes all input from the Steam Controller and instead registers a virtual gamepad that obeys the Big Picture controller remapping.  We want to make sure to pick that one, since the "real" Steam Controller doesn't report any events while the virtual device is active.  So we carefully consider the "real" Steam Controller "inactive" if the presence of the virtual device is detected, until the virtual device is disconnected (ie. when Steam is closed) or if it turns out that it is generating events after all, in which case it gets automatically reactivated.

This is a bit of a hack, maybe there is a cleaner way of doing this.
2019-01-02 00:56:40 +01:00
rdb f3ba1d317c device: support for Steam Controller on Linux
Adds lgrip and rgrip button handles, which are present on Steam Controller but also on the Oculus Touch
2018-12-31 16:10:56 +01:00
rdb 8119547e90 device: add hacky detection of Trust GXT 24 as gamepad for now 2018-12-31 13:12:40 +01:00
rdb 585ba2d647 Prepare input API for multipointer support 2018-11-30 20:54:37 +01:00
rdb 2087d8ee84 device: change InputDevice enums to enum classes 2018-11-30 20:41:06 +01:00
rdb ada3fa5513 Compile fixes on input-overhaul branch 2018-10-08 01:44:17 +02:00
rdb 4b77812b35 device: fix inverted flight stick throttle on Linux 2018-10-07 20:49:13 +02:00
rdb f518b9aaf1 device: fixes to sporadic device class detection on Linux 2018-10-07 20:48:39 +02:00
rdb 8edc019307 device: overhaul InputDevice API:
- Rename "controls" terminology for analog inputs to "axes"
- Change some naming of accessors
- Unexpose methods where they are available as properties
- Add serial_number field
- Put battery levels under a "battery" field
2018-09-16 20:22:22 +02:00
rdb 8d8c5a546d input: rename "action_x" button handles to "face_x" 2018-09-16 14:50:00 +02:00
rdb 7cc100c38c device: change ControlAxis enum to an Axis enum class 2018-08-26 21:18:29 +02:00
rdb 11723b27ee device: various warning fixes for input-overhaul on Linux 2018-06-23 23:30:44 +02:00
rdb 234fd675b1 Merge branch 'master' into input-overhaul 2018-06-23 23:24:09 +02:00
rdb ba2de46beb Merge branch 'master' into input-overhaul 2018-06-08 15:23:47 +02:00
Mitchell Stokes aaf7ff9a6c device: Define BTN_DPAD* if not present 2018-05-05 18:12:52 -07:00
rdb 664d628cbc device: D-Pad mappings for DualShock 3 driver on Linux 2018-04-05 21:05:02 +02:00
rdb 9e6d0d91ad input: fixes for older Android API levels (thanks to pmp-p) 2018-02-04 10:58:36 +01:00
rdb 3da32b7b7c input: split out LinuxInputDeviceManager from InputDeviceManager 2018-01-25 20:15:16 +01:00
rdb f189b817c6 input: fix name/manufacturer/serial fetching for some evdev devices 2018-01-23 12:59:14 +01:00
rdb 712b246dd6 input: reverse rudder direction to match yaw, reverse 3D mouse roll
Although having the rudder reversed is less intuitive, this makes it match the Panda convention for "heading".
2018-01-23 12:58:40 +01:00
rdb 2523bb0326 input: fixes for 3D mouse axes on Linux 2018-01-07 17:36:52 +01:00
rdb 9fbdefe120 input: add analog trigger emulation on Linux 2018-01-07 17:26:48 +01:00
rdb 4f739e88cf input: joystick buttons, use yaw/pitch/roll for axes, more devices
Also adds format_* functions to get string from enum value.
2018-01-07 14:50:54 +01:00
rdb ba8cbfd056 input: fixes for Linux scoring and axis/button mapping
This adds a list of known devices so that we can assign custom behavior to them.  I tested this with the T.Flight Hotas X flight stick and the NVIDIA Shield Controller.
2017-12-22 17:45:06 +01:00
rdb 12cfc93b79 input: let InputDevice manage axis remapping, add C_twist axis 2017-12-22 15:21:50 +01:00
fireclawthefox f1e1c2b891 Fixes for device button handling
Made State enum accessible from python side
Fixed missing state changing in evdevInputDevice class
2017-02-08 17:04:28 +01:00
rdb fa7f385bb8 More work on integrating new input framework 2016-12-28 17:25:55 +01:00
fireclawthefox 2da890800f Fix hat mapping if dpad emulation is deactivated 2016-08-11 12:05:07 +02:00
fireclawthefox 719e77a191 Changed button mapping
changed mapping of previous and next (i.e. wiimote's + and - keys) to
the same as the select and start button
2016-08-10 16:46:20 +02:00
fireclawthefox e1661111c2 Exposed AnalogState and ButtonState
Published Analog- and ButtonState to be accessible from python
Added functions to find Controls and buttons to simplify access
Refactored highscore search for setting the device class
2016-08-04 22:52:01 +02:00
fireclawthefox 670efb9e64 Extended device class heuristics
Extended and partly restructured the way how the device class gets set
Added DC_COUNT to the DeviceClass enum to simplify loop checks
2016-08-03 20:20:01 +02:00
fireclawthefox dcdbe4b339 Add handling for new gamepad buttons
Added handles to 1, 2, next and previous as available on the wiimote
2016-07-21 12:44:44 +02:00
rdb c7dbf193f1 Fix Linux crash with Xbox One controller, fix compile warnings 2016-06-28 17:49:47 +02:00
rdb fd16e34660 Fix Xbox One controller on Windows, add untested support for flight sticks and steering wheels 2016-06-24 13:32:10 +02:00
rdb 01e57e1bdd Emulate d-pad from hat axes, fixes Xbox One d-pad buttons on Linux 2016-06-24 10:54:57 +02:00
rdb 1cc79633c1 Merge branch 'master' into input-overhaul
Conflicts:
	panda/src/device/buttonNode.cxx
	panda/src/device/clientAnalogDevice.I
	panda/src/device/clientAnalogDevice.cxx
	panda/src/device/clientButtonDevice.I
	panda/src/device/clientButtonDevice.cxx
	panda/src/device/clientDevice.I
	panda/src/device/clientDevice.cxx
	panda/src/device/clientDevice.h
	panda/src/device/clientTrackerDevice.I
	panda/src/device/trackerNode.I
	panda/src/device/trackerNode.h
	panda/src/display/callbackGraphicsWindow.cxx
	panda/src/display/graphicsWindow.cxx
	panda/src/display/graphicsWindowInputDevice.I
	panda/src/display/graphicsWindowInputDevice.cxx
	panda/src/display/graphicsWindowInputDevice.h
	panda/src/tinydisplay/tinyOsxGraphicsWindow.mm
	panda/src/tinydisplay/tinyXGraphicsWindow.cxx
	panda/src/windisplay/winGraphicsWindow.cxx
	panda/src/windisplay/winGraphicsWindow.h
	panda/src/x11display/x11GraphicsWindow.cxx
2016-03-19 14:54:56 +01:00
rdb bfea37f64d Detect keyboard devices on Linux 2015-12-19 20:09:07 +01:00
rdb 687e080bdd Add gamepad rumble support on Linux 2015-12-19 19:40:24 +01:00
rdb ab66108661 Robustify Linux gamepad support 2015-12-19 16:03:28 +01:00
rdb 58ddd77d5e Support gamepads (and other devices) via evdev interface, query axis+button availability 2015-12-11 19:32:45 +01:00
rdb bd0683d101 Generalised input framework for raw mice, gamepads, trackers (incl. HMDs like Oculus Rift) 2015-12-11 15:26:40 +01:00