29 Commits

Author SHA1 Message Date
gblues
fb5b31faf3 Merge branch 'master' into gblues/hid 2018-04-14 14:18:03 -07:00
twinaphex
a82bb0ec94 Create special type input_bits_t 2018-04-08 20:21:12 +02:00
gblues
0100d58ffb WIP: evolve driver implementation
== DETAILS

I've created the concept of a hid_driver_instance_t which is basically
a central place to store the hid pad driver, hid subsystem driver,
the pad list, and the instance data for the above in a central location.

The HID pad device drivers can use it to perform HID operations in a
generic manner.

This is more-or-less a pause point so I can catch up with upstream.

== TESTING

Haven't tested this yet. Compiles without warnings though!
2018-03-29 23:37:11 -07:00
twinaphex
b464014a51 C89_BUILD fixes 2017-12-31 03:27:55 +01:00
gblues
678c4093c1 Start adapting the dual shock 3 driver to use the new driver format.
== DETAILS

The handshake stuff is derived from the old HID2VPAD, just in knowing
what data goes in what report.

- Added the HID_REPORT_ flags to syshid.h
- Renamed the generic "REPORT_TYPE" flags to be meaningful
- also fixed incorrect parameter list for set_protocol
== TESTING
The functions aren't implemented in wiiu_hid.c just yet,
so this is gonna crash if you try to run it.
2017-12-30 04:41:12 +01:00
gblues
5b37ced196 Update HID pad driver architecture
== DETAILS

The current HID implementation assumes a very low-level USB library
is being used. This causes a problem on Wii U, because the Cafe OS
only exposes a high-level interface.

To get these functions exposed to the HID pad drivers, I had to make
three changes:

1. I added the legacy "send_control" function to the HID driver
   interface
2. I modified the signature of pad_connection_pad_init() to send the
   driver pointer instead of the function pointer
3. I updated the HID pad drivers to keep the pointer to the driver
   instead of the function pointer, and updated the calls into the
   send_control function as appropriate
4. I updated the HID drivers to use the new pad init signature

== TESTING
Untested, in theory it should work without a hitch because at this
point all I've done is abstract things a little. I still need to
update the HID pad drivers to use the Wii U-specific calls as
appropriate.
2017-12-30 04:41:01 +01:00
twinaphex
f0c143766e Change to 256bit macros 2017-12-05 12:07:35 +01:00
twinaphex
6c09661a64 Move defines to retro_miscellaneous.h 2017-12-05 10:42:37 +01:00
twinaphex
e94300a581 Get rid of a lot of RARCH_INPUT_STATE_BIT_ macros - replace them
with BIT128_ equivalents instead
2017-12-05 09:22:56 +01:00
David Walters
c5bdc02d6f replace uint64_t with retro_bits_t* for pad buttons state 2017-11-28 10:04:34 +00:00
twinaphex
96c8ca5a09 Header update #1 2017-01-22 13:40:32 +01:00
netux79
bca4ccb155 (GX) Refactor of the Wii USB HID support. Now it's working!
In order to have a controller working you need:
1) Have a matching HID autoconfig file in autoconfig/hid for your controller.
2) Create a "connect" driver for the pad in "input/connect" folder (source code of RA).
3) Once you are in RA, change the joystick driver to HID and restart.
4) You may be now able to use you USB HID compatible pad in RA.

I included some "connect" drivers as an example. It also need to include them for compilation.
2016-02-04 17:01:03 -05:00
twinaphex
2e8f015de3 Cleanups 2016-02-04 21:07:02 +01:00
twinaphex
347a18cb30 Update input headers 2016-01-10 04:33:01 +01:00
twinaphex
e74e402cdc More C89 build fixes 2015-06-30 14:37:11 +02:00
twinaphex
2087a41f20 (connect) Style nits 2015-04-07 18:49:21 +02:00
twinaphex
6433cdf2e7 (input/connect) Cleanups 2015-04-02 18:48:44 +02:00
twinaphex
738d70d2f8 Add get_buttons callback 2015-02-15 01:57:29 +01:00
Twinaphex
da24b62de9 (Apple) Build fixes 2015-01-19 05:05:41 +01:00
twinaphex
824f00be15 (input/connect) Cleanups 2015-01-19 05:01:31 +01:00
twinaphex
453321c50b Start updating headers 2015-01-07 17:46:50 +01:00
twinaphex
f08f78e86a (joypad_connection) start calling 'connect' function 'init'
and 'disconnect' 'deinit'
2014-10-22 07:59:52 +02:00
twinaphex
c62d52de0f Start properly implementing libretro SDK for boolean.h include
header, glsym, and rthreads
2014-10-21 05:05:52 +02:00
twinaphex
0fb301fa43 (joypad/connect) Change 'index' local variables 2014-10-20 20:32:41 +02:00
twinaphex
303aaede17 Update to connect_ps3.c 2014-10-16 22:37:06 +02:00
twinaphex
7c842f9342 More stdio.h header include removals 2014-10-16 07:29:42 +02:00
Lioncash
316870201f Fix possible memory leaks in hidpad_ps3_connect, hidpad_ps4_connect, and hidpad_wii_connect 2014-10-13 17:39:14 -04:00
twinaphex
21d9185e96 (connect_ps3.c) Optimize 2014-10-05 03:48:55 +02:00
twinaphex
d4a14c4cb9 Move joypad_connection code to input/connect 2014-10-04 23:02:48 +02:00