mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-02-23 09:41:15 +00:00
HW/SI: GCAdapter calibration fix.
This commit is contained in:
parent
9b6c9252e4
commit
a015851b02
@ -18,6 +18,9 @@ namespace SerialInterface
|
|||||||
CSIDevice_GCAdapter::CSIDevice_GCAdapter(SIDevices device, int device_number)
|
CSIDevice_GCAdapter::CSIDevice_GCAdapter(SIDevices device, int device_number)
|
||||||
: CSIDevice_GCController(device, device_number)
|
: CSIDevice_GCController(device, device_number)
|
||||||
{
|
{
|
||||||
|
// Make sure PAD_GET_ORIGIN gets set due to a newly connected device.
|
||||||
|
GCAdapter::ResetDeviceType(m_device_number);
|
||||||
|
|
||||||
// get the correct pad number that should rumble locally when using netplay
|
// get the correct pad number that should rumble locally when using netplay
|
||||||
const int pad_num = NetPlay_InGamePadToLocalPad(m_device_number);
|
const int pad_num = NetPlay_InGamePadToLocalPad(m_device_number);
|
||||||
if (pad_num < 4)
|
if (pad_num < 4)
|
||||||
|
@ -485,6 +485,11 @@ bool DeviceConnected(int chan)
|
|||||||
return s_controller_type[chan] != ControllerTypes::CONTROLLER_NONE;
|
return s_controller_type[chan] != ControllerTypes::CONTROLLER_NONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ResetDeviceType(int chan)
|
||||||
|
{
|
||||||
|
s_controller_type[chan] = ControllerTypes::CONTROLLER_NONE;
|
||||||
|
}
|
||||||
|
|
||||||
bool UseAdapter()
|
bool UseAdapter()
|
||||||
{
|
{
|
||||||
const auto& si_devices = SConfig::GetInstance().m_SIDevice;
|
const auto& si_devices = SConfig::GetInstance().m_SIDevice;
|
||||||
|
@ -29,6 +29,7 @@ void Output(int chan, u8 rumble_command);
|
|||||||
bool IsDetected();
|
bool IsDetected();
|
||||||
bool IsDriverDetected();
|
bool IsDriverDetected();
|
||||||
bool DeviceConnected(int chan);
|
bool DeviceConnected(int chan);
|
||||||
|
void ResetDeviceType(int chan);
|
||||||
bool UseAdapter();
|
bool UseAdapter();
|
||||||
|
|
||||||
} // end of namespace GCAdapter
|
} // end of namespace GCAdapter
|
||||||
|
@ -382,6 +382,11 @@ bool DeviceConnected(int chan)
|
|||||||
return s_controller_type[chan] != ControllerTypes::CONTROLLER_NONE;
|
return s_controller_type[chan] != ControllerTypes::CONTROLLER_NONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ResetDeviceType(int chan)
|
||||||
|
{
|
||||||
|
s_controller_type[chan] = ControllerTypes::CONTROLLER_NONE;
|
||||||
|
}
|
||||||
|
|
||||||
bool UseAdapter()
|
bool UseAdapter()
|
||||||
{
|
{
|
||||||
const auto& si_devices = SConfig::GetInstance().m_SIDevice;
|
const auto& si_devices = SConfig::GetInstance().m_SIDevice;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user