mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-23 01:39:17 +01:00
Refresh calibration data when pairing to or disconnecting a device from the Sony dongle
This commit is contained in:
parent
3a09132805
commit
0df84e1fba
@ -472,6 +472,14 @@ namespace DS4Windows
|
||||
}
|
||||
}
|
||||
|
||||
public void refreshCalibration()
|
||||
{
|
||||
byte[] calibration = new byte[41];
|
||||
calibration[0] = conType == ConnectionType.BT ? (byte)0x05 : (byte)0x02;
|
||||
hDevice.readFeatureData(calibration);
|
||||
sixAxis.setCalibrationData(ref calibration, conType == ConnectionType.USB);
|
||||
}
|
||||
|
||||
public void StartUpdate()
|
||||
{
|
||||
if (ds4Input == null)
|
||||
|
@ -197,6 +197,8 @@ namespace DS4Windows
|
||||
{
|
||||
deviceSerials.Add(serial);
|
||||
}
|
||||
|
||||
device.refreshCalibration();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user