dolphin/Source/Core/Core
Ryan Houdek 1dcc199a63 Fix GCPad recalibration shortcut.
Dolphin has supported the recalibration shortcut (X+Y+Start) for quite a long while. So if someont's axises are terrible, you could easily
recalibrate.
Games even get the initial calibration upon boot(Most of the time).

While changing over the GCAdapter code, I was testing to make sure the reset and calibration shortcuts still worked, turns out they didn't work at
all.
Looking in to the problem, we capture the combination properly, and we wait three seconds until we actually fire that off recalibration.
The problem is for Nintendo's SDK to properly handle recalibrating, we need to send back data saying that it needs to recalibrate.
On hardware this is done as part of the 64bits of data the controller sends back to us.
On holding of the controller, bit 61 of the return value is set, which the Nintendo SDK catches, and then signals immediately afterwards a CMD_ORIGIN
command in order to recalibrate the controller.
We were outright ignoring this bit, so the library wasn't ever recalibrating. I suspect in the past the class itself used to use the calibration data
to to offset the data, but somewhere along the lines it got munged out of existence.

The Gamecube adapter does this shortcut in a bit of a unique way, instead of sending the command and having the library support it and what have you.
Once holding the shortcut for the amount of time, the adapter reports back that the controller has actually been disconnected. Then when you let go of
the combination, the adapter states that a new device has been connected to that port, and the recalibration happens because a new device is
"connected."

This fixes controller calibration for both emulated GC controllers and also the Wii Gamecube Adapter.
2016-01-06 00:41:00 -06:00
..
Boot VI: set the JP bit of VI's DTV reg when needed 2015-12-31 05:36:29 +08:00
Debugger WII_IPC_HLE_Device_usb: const correctness for function parameters 2015-12-05 16:14:37 -05:00
DSP DSPCore: Prefix globals with g_ 2015-12-29 10:40:44 -05:00
FifoPlayer FifoAnalyzer: Fix a few warnings that visual studio missed. 2015-12-28 20:20:30 +13:00
HLE Common: Remove other Common prefixed headers from Common.h 2015-09-26 18:51:58 -04:00
HW Fix GCPad recalibration shortcut. 2016-01-06 00:41:00 -06:00
IPC_HLE Merge pull request #3362 from lioncash/memory 2015-12-22 06:39:12 -05:00
PowerPC Merge pull request #3408 from Tilka/fcmp 2016-01-04 22:19:32 -05:00
ActionReplay.cpp Merge pull request #3067 from JosJuice/cheat-manager-regression 2015-12-02 14:08:32 +01:00
ActionReplay.h Fix Cheat Manager not saving created codes 2015-09-19 17:20:16 +02:00
ARDecrypt.cpp Core: Pass several parameters by const reference 2015-06-04 14:19:25 -04:00
ARDecrypt.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
BootManager.cpp Merge pull request #3250 from JosJuice/loadgameini-condition 2015-12-22 13:24:09 +13:00
BootManager.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
CMakeLists.txt Make the Wii U Gamecube adapter work with less magic. 2016-01-05 13:44:37 -06:00
ConfigManager.cpp Fix GCPad recalibration shortcut. 2016-01-06 00:41:00 -06:00
ConfigManager.h Fix GCPad recalibration shortcut. 2016-01-06 00:41:00 -06:00
Core.cpp Move SI_GCAdapter over to InputCommon 2016-01-05 13:44:37 -06:00
Core.h Synchronize DVDInterface::ChangeDisc with the CPU thread properly. 2015-11-03 12:42:05 +01:00
Core.vcxproj Make the Wii U Gamecube adapter work with less magic. 2016-01-05 13:44:37 -06:00
Core.vcxproj.filters Make the Wii U Gamecube adapter work with less magic. 2016-01-05 13:44:37 -06:00
CoreTiming.cpp Partially revert "General: Toss out PRI macro usage" 2015-09-11 09:49:00 -04:00
CoreTiming.h CoreTiming: remove unused functions 2015-08-26 15:40:15 +02:00
DSPEmulator.cpp Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
DSPEmulator.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
ec_wii.cpp Merge pull request #3091 from Tilka/mbedtls 2015-10-03 18:00:58 -07:00
ec_wii.h Update license headers to GPLv2+ 2015-05-25 13:22:31 +02:00
GeckoCode.cpp Options: merge SCoreStartupParameter into SConfig 2015-06-12 19:07:45 +02:00
GeckoCode.h GeckoCode: Remove GetAddress function prototype 2015-07-28 22:10:39 -04:00
GeckoCodeConfig.cpp Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
GeckoCodeConfig.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
Host.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
HotkeyManager.cpp Added hotkey for toggling the crop setting 2016-01-04 10:10:49 -05:00
HotkeyManager.h Added hotkey for toggling the crop setting 2016-01-04 10:10:49 -05:00
MachineContext.h Remove ARMv7 support. 2015-06-07 22:44:13 -05:00
MemoryWatcher.cpp Fix building with PCH disabled. 2016-01-01 10:26:15 -06:00
MemoryWatcher.h Allow MemoryWatcher to follow pointers 2015-12-30 19:10:31 -08:00
MemTools.cpp Include unistd.h in memtools.cpp to fix nopch 2015-10-09 11:08:17 +02:00
MemTools.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
Movie.cpp Movie: Fix "Pause at End of Movie" for wii games. 2015-12-30 23:11:40 -05:00
Movie.h State/Movie: Use char instead of u8 for game ID 2015-11-28 09:36:48 +01:00
NetPlayClient.cpp Merge pull request #2873 from lioncash/netleaks 2015-09-16 21:56:17 +02:00
NetPlayClient.h General: Remove unimplemented function prototypes 2015-09-05 22:01:07 -04:00
NetPlayProto.h NetPlay: Use std::array for the pad mappings 2015-08-16 00:08:09 -04:00
NetPlayServer.cpp Merge pull request #2876 from CastellaFactory/master 2015-12-02 14:20:47 +01:00
NetPlayServer.h Add missing override specifiers 2015-09-05 22:40:19 -04:00
PatchEngine.cpp Options: merge SCoreStartupParameter into SConfig 2015-06-12 19:07:45 +02:00
PatchEngine.h Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
State.cpp Blocked netplay users from desyncing by messing with savestates. 2015-12-31 18:50:45 -06:00
State.h State/Movie: Use char instead of u8 for game ID 2015-11-28 09:36:48 +01:00