98 WUT_UNKNOWN_BYTES(3 * 4);
103 WUT_UNKNOWN_BYTES(8 * 4);
177 WUT_UNKNOWN_BYTES(20 * 4);
180 WUT_UNKNOWN_BYTES(16 * 4);
186 WUT_CHECK_OFFSET(
KPADStatus, 0x18, accMagnitude);
187 WUT_CHECK_OFFSET(
KPADStatus, 0x1C, accVariation);
190 WUT_CHECK_OFFSET(
KPADStatus, 0x5C, extensionType);
195 WUT_CHECK_OFFSET(
KPADStatus, 0x60, nunchuk.stick);
206 WUT_CHECK_OFFSET(
KPADStatus, 0x6C, classic.leftStick);
207 WUT_CHECK_OFFSET(
KPADStatus, 0x74, classic.rightStick);
208 WUT_CHECK_OFFSET(
KPADStatus, 0x7C, classic.leftTrigger);
209 WUT_CHECK_OFFSET(
KPADStatus, 0x80, classic.rightTrigger);
214 WUT_CHECK_OFFSET(
KPADStatus, 0x6C, pro.leftStick);
215 WUT_CHECK_OFFSET(
KPADStatus, 0x74, pro.rightStick);
216 WUT_CHECK_OFFSET(
KPADStatus, 0x7C, pro.charging);
217 WUT_CHECK_OFFSET(
KPADStatus, 0x80, pro.wired);
uint8_t extensionType
Value from KPADExtensionType.
KPADVec3D acc
Indicates the value of the acceleration sensor.
uint32_t hold
Indicates what KPADButtons are held down.
int8_t posValid
Validity of the result.
uint8_t format
Value from KPADDataFormat.
uint32_t release
Indicates what KPADButtons have been released since last sample.
int8_t error
Value from KPADError.
uint32_t trigger
Indicates what KPADButtons have been pressed since last sample.
float accVariation
Indicates the variation in acceleration.
float accMagnitude
Indicates the magnitude of acceleration.
KPADVec2D pos
Indicates the position where the Wii Remote is pointing.
WPADConnectCallback KPADConnectCallback
void KPADShutdown()
Cleans up and frees the KPAD library.
enum WPADExtensionType KPADExtensionType
Extension type.
enum WPADDataFormat KPADDataFormat
Data format.
void KPADDisableDPD(KPADChan chan)
Disable IR pointing.
KPADConnectCallback KPADSetConnectCallback(KPADChan chan, KPADConnectCallback callback)
Set a callback for when a controller connection status changes.
uint32_t KPADGetGameMaxControllers(void)
Get the maximum amount of controllers which can be connected, as reported by IOS-PAD.
void KPADInit()
Initialises the KPAD library for use.
enum WPADMplsMode KPADMplsMode
MotionPlus Mode.
uint32_t KPADGetMaxControllers(void)
Get the maximum amount of controllers which can be connected to the system.
void KPADDisableMpls(KPADChan channel)
Disables MotionPlus for the controller.
enum WPADChan KPADChan
Wii Remote channel.
int32_t KPADRead(KPADChan chan, KPADStatus *data, uint32_t size)
Read data from the desired controller.
KPADMplsMode KPADGetMplsStatus(KPADChan chan)
Get MotionPlus mode.
int32_t KPADReadEx(KPADChan chan, KPADStatus *data, uint32_t size, KPADError *error)
Read data from the desired controller.
void KPADEnableMpls(KPADChan channel, KPADMplsMode mode)
Sets MotionPlus for the controller in specified mode.
void KPADEnableDPD(KPADChan chan)
Enable IR pointing.
int32_t KPADSetMaxControllers(uint32_t maxControllers)
Set the maximum amount of controllers which can be connected to the system.
@ KPAD_ERROR_OK
No error occurred, and data was written to the buffers.
@ KPAD_ERROR_WPAD_UNINIT
WPAD is uninitialized, shouldn't happen unless WPADShutdown() is manually called.
@ KPAD_ERROR_BUSY
KPAD channel is busy, perhaps being accessed by another thread.
@ KPAD_ERROR_NO_SAMPLES
There was no sample new data available to write.
@ KPAD_ERROR_INVALID_CONTROLLER
The requested controller or channel was invalid.
@ KPAD_ERROR_UNINITIALIZED
KPAD is uninitialized, need to call KPADInit()
A structure containing the Wii Remote data.
WPADDataFormat
Data format.
WPADChan
Wii Remote channel.
WPADExtensionType
Extension type.
WPADMplsMode
MotionPlus Mode.
void(* WPADConnectCallback)(WPADChan chan, int32_t status)
Callback called when a controller connects or disconnects.