PADReset

Syntax

#include <revolution/pad.h>

#define PAD_CHAN0_BIT           0x80000000
#define PAD_CHAN1_BIT           0x40000000
#define PAD_CHAN2_BIT           0x20000000
#define PAD_CHAN3_BIT           0x10000000

BOOL PADReset(u32 mask);

Arguments

mask OR bitmask of the controller(s) to be reset.

Return Values

TRUE if the reset sequence is successfully started. Otherwise, FALSE.

PADReset may return a value of FALSE if the controller port interface was busy performing other transactions. In that case, PADReset should be called repeatedly until PADRead detects a return value other than an error. Be aware that if PADRead is called immediately after PADRecalibrate has succeeded, the returned PADStatus for the specified ports may contain either a PAD_ERR_NOT_READY or PAD_ERR_TRANSFER error code.

Description

Resets the specified controller(s). This function returns FALSE if the controller port interface is busy carrying out other processing. If this happens, PADReset must be called again until PADRead detects a return value other than the PAD_ERR_NO_CONTROLLER error code.

See Also

PADButtonDown, PADButtonUp, PADInit, PADRead, PADStatus

Revision History

2006/03/01 Initial version.


CONFIDENTIAL