MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / PADRecalibrate

Function PADRecalibrate

src/dolphin/src/pad/Pad.c:327–353  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

325}
326
327BOOL PADRecalibrate(u32 mask)
328{
329 BOOL enabled;
330 u32 disableBits;
331
332 enabled = OSDisableInterrupts();
333
334 mask |= PendingBits;
335 PendingBits = 0;
336 mask &= ~(WaitingBits | CheckingBits);
337 ResettingBits |= mask;
338 disableBits = ResettingBits & EnabledBits;
339 EnabledBits &= ~mask;
340
341 if (!(UnkVal & 0x40))
342 {
343 RecalibrateBits |= mask;
344 }
345
346 SIDisablePolling(disableBits);
347 if (ResettingChan == 32)
348 {
349 DoReset();
350 }
351 OSRestoreInterrupts(enabled);
352 return TRUE;
353}
354
355BOOL PADInit()
356{

Callers 2

OnResetFunction · 0.85
CheckResetButtonMethod · 0.85

Calls 3

OSDisableInterruptsFunction · 0.85
SIDisablePollingFunction · 0.85
DoResetFunction · 0.85

Tested by

no test coverage detected