MCPcopy Create free account
hub / github.com/cathery/sys-con / GetInput

Method GetInput

source/ControllerLib/Controllers/Dualshock4Controller.cpp:116–130  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

114}
115
116Result Dualshock4Controller::GetInput()
117{
118
119 uint8_t input_bytes[64];
120
121 Result rc = m_inPipe->Read(input_bytes, sizeof(input_bytes));
122 if (R_FAILED(rc))
123 return rc;
124
125 if (input_bytes[0] == 0x01)
126 {
127 m_buttonData = *reinterpret_cast<Dualshock4USBButtonData *>(input_bytes);
128 }
129 return rc;
130}
131
132float Dualshock4Controller::NormalizeTrigger(uint8_t deadzonePercent, uint8_t value)
133{

Callers

nothing calls this directly

Calls 1

ReadMethod · 0.80

Tested by

no test coverage detected