#include <revolution/wpad.h>
#define WPAD_CHAN0 0
#define WPAD_CHAN1 1
#define WPAD_CHAN2 2
#define WPAD_CHAN3 3
#define WPAD_DEV_CORE 0
#define WPAD_DEV_FREESTYLE 1
#define WPAD_DEV_CLASSIC 2
#define WPAD_DEV_NOT_FOUND 253
#define WPAD_DEV_UNKNOWN 255
#define WPAD_ERR_NONE 0
#define WPAD_ERR_NO_CONTROLLER -1
#define WPAD_ERR_BUSY -2
#define WPAD_ERR_TRANSFER -3
s32 WPADProbe( s32 chan, u32 *type );
chan |
One of WPAD_CHANn values. |
type |
Pointer to the variable for getting the controller type. |
Returns the error status.
Error statuses are defined with the following macro constants.
WPAD_ERR_NONECommunicated successfully with the Wii Remote. The typevariable contains a valid controller type.WPAD_ERR_NO_CONTROLLERThe Wii Remote is not connected. The typevariable does not contain a valid controller type (undefined).WPAD_ERR_BUSYProcessing is occurring for the Wii Remote. The typevariable does not contain a valid controller type (undefined).WPAD_ERR_TRANSFERA problem occurred during prior communications. The typevariable does not contain a valid controller type (undefined).
Checks the specified channel's controller type.
Controller types are defined with the following macro constants.
WPAD_DEV_NOT_FOUNDNothing is connected to the specified channel. WPAD_DEV_COREWii Remote. WPAD_DEV_FREESTYLENunchuk Style. WPAD_DEV_CLASSICClassic Style. WPAD_DEV_UNKNOWNUnknown device.
06/19/2006 Added WPAD_DEV_CLASSIC to controller types, revised error status.
10/27/2005 Initial version.
CONFIDENTIAL