mirror of
https://github.com/cathery/sys-con.git
synced 2024-07-05 10:48:46 +00:00
parent
4d498a211d
commit
f0419185f4
|
@ -155,8 +155,8 @@ private:
|
||||||
|
|
||||||
Dualshock3ButtonData m_buttonData;
|
Dualshock3ButtonData m_buttonData;
|
||||||
|
|
||||||
int8_t kLeftThumbDeadzone = 0;
|
int8_t kLeftThumbDeadzone = 10;
|
||||||
int8_t kRightThumbDeadzone = 0;
|
int8_t kRightThumbDeadzone = 10;
|
||||||
int8_t kTriggerMax = 0;
|
int8_t kTriggerMax = 0;
|
||||||
int8_t kTriggerDeadzone = 0;
|
int8_t kTriggerDeadzone = 0;
|
||||||
|
|
||||||
|
|
|
@ -51,8 +51,8 @@ private:
|
||||||
|
|
||||||
Dualshock4ButtonData m_buttonData;
|
Dualshock4ButtonData m_buttonData;
|
||||||
|
|
||||||
int16_t kLeftThumbDeadzone = 0; //7849;
|
int16_t kLeftThumbDeadzone = 2000; //7849;
|
||||||
int16_t kRightThumbDeadzone = 0; //8689;
|
int16_t kRightThumbDeadzone = 2000; //8689;
|
||||||
uint16_t kTriggerMax = 0; //1023;
|
uint16_t kTriggerMax = 0; //1023;
|
||||||
uint16_t kTriggerDeadzone = 0; //120;
|
uint16_t kTriggerDeadzone = 0; //120;
|
||||||
|
|
||||||
|
|
|
@ -68,8 +68,8 @@ private:
|
||||||
|
|
||||||
Xbox360ButtonData m_buttonData;
|
Xbox360ButtonData m_buttonData;
|
||||||
|
|
||||||
int16_t kLeftThumbDeadzone = 0; //7849;
|
int16_t kLeftThumbDeadzone = 8000; //7849;
|
||||||
int16_t kRightThumbDeadzone = 0; //8689;
|
int16_t kRightThumbDeadzone = 8000; //8689;
|
||||||
uint16_t kTriggerMax = 0; //1023;
|
uint16_t kTriggerMax = 0; //1023;
|
||||||
uint16_t kTriggerDeadzone = 0; //120;
|
uint16_t kTriggerDeadzone = 0; //120;
|
||||||
|
|
||||||
|
|
|
@ -79,9 +79,10 @@ private:
|
||||||
IUSBEndpoint *m_outPipe = nullptr;
|
IUSBEndpoint *m_outPipe = nullptr;
|
||||||
|
|
||||||
XboxOneButtonData m_buttonData;
|
XboxOneButtonData m_buttonData;
|
||||||
|
bool m_GuidePressed;
|
||||||
|
|
||||||
int16_t kLeftThumbDeadzone = 0; //7849;
|
int16_t kLeftThumbDeadzone = 2500; //7849;
|
||||||
int16_t kRightThumbDeadzone = 0; //8689;
|
int16_t kRightThumbDeadzone = 3500; //8689;
|
||||||
uint16_t kTriggerMax = 0; //1023;
|
uint16_t kTriggerMax = 0; //1023;
|
||||||
uint16_t kTriggerDeadzone = 0; //120;
|
uint16_t kTriggerDeadzone = 0; //120;
|
||||||
uint8_t m_rumbleDataCounter = 0;
|
uint8_t m_rumbleDataCounter = 0;
|
||||||
|
@ -109,5 +110,5 @@ public:
|
||||||
|
|
||||||
Status SendInitBytes();
|
Status SendInitBytes();
|
||||||
Status WriteAckGuideReport(uint8_t sequence);
|
Status WriteAckGuideReport(uint8_t sequence);
|
||||||
Status SetRumble(uint8_t strong_magnitude,uint8_t weak_magnitude);
|
Status SetRumble(uint8_t strong_magnitude, uint8_t weak_magnitude);
|
||||||
};
|
};
|
|
@ -95,7 +95,7 @@ Status XboxOneController::GetInput()
|
||||||
}
|
}
|
||||||
else if (type == XBONEINPUT_GUIDEBUTTON) //Guide button status
|
else if (type == XBONEINPUT_GUIDEBUTTON) //Guide button status
|
||||||
{
|
{
|
||||||
m_buttonData.sync = input_bytes[4];
|
m_GuidePressed = input_bytes[4];
|
||||||
|
|
||||||
//Xbox one S needs to be sent an ack report for guide buttons
|
//Xbox one S needs to be sent an ack report for guide buttons
|
||||||
//TODO: needs testing
|
//TODO: needs testing
|
||||||
|
@ -188,10 +188,10 @@ NormalizedButtonData XboxOneController::GetNormalizedButtonData()
|
||||||
normalData.left_stick_click = m_buttonData.stick_left_click;
|
normalData.left_stick_click = m_buttonData.stick_left_click;
|
||||||
normalData.right_stick_click = m_buttonData.stick_right_click;
|
normalData.right_stick_click = m_buttonData.stick_right_click;
|
||||||
|
|
||||||
normalData.capture = false;
|
normalData.capture = m_buttonData.sync;
|
||||||
normalData.home = false;
|
normalData.home = false;
|
||||||
|
|
||||||
normalData.guide = m_buttonData.sync;
|
normalData.guide = m_GuidePressed;
|
||||||
|
|
||||||
normalData.left_trigger = NormalizeTrigger(m_buttonData.trigger_left);
|
normalData.left_trigger = NormalizeTrigger(m_buttonData.trigger_left);
|
||||||
normalData.right_trigger = NormalizeTrigger(m_buttonData.trigger_right);
|
normalData.right_trigger = NormalizeTrigger(m_buttonData.trigger_right);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user