#include <revolution/pad.h>
#define PAD_MODE_0 0
#define PAD_MODE_1 1
#define PAD_MODE_2 2
#define PAD_MODE_3 3
#define PAD_MODE_4 4
#define PAD_MODE_5 5
#define PAD_MODE_6 6
#define PAD_MODE_7 7
void PADSetAnalogMode(u32 mode);
mode |
One of the PAD_MODE_* constants. |
None.
There is no need to use this function.
Specifies the controller analog mode to be used. The analog mode controls the resolution of the controller's analog inputs as stored in PADStatus and as shown below. The default mode is PAD_MODE_3.
NB: The PADSetAnalogMode function pauses the hardware controller sampling. The next PADRead function returns PAD_ERR_NO_CONTROLLER errors for any connected controllers. The specified analog mode takes effect after the next call to PADReset or PADInit. Note that PADSetAnalogMode() may be called before PADInit().
NB: GameCube standard controllers do not support analog input values (AnalogA/B) for A or B Buttons. Also, the Revolution controller library WPAD does not support analog input values from the A and B Buttons.
stickX, stickY |
All 8 bits are valid. |
substickX, substickY |
All 8 bits are valid. |
triggerLeft, triggerRight |
Uppermost 4 bits are valid. Other bits are set to zero. |
analogA, analogB |
Uppermost 4 bits are valid. Other bits are set to zero. |
stickX, stickY |
All 8 bits are valid. |
substickX, substickY |
Uppermost 4 bits are valid. Other bits are set to zero. |
triggerLeft, triggerRight |
All 8 bits are valid. |
analogA, analogB |
Uppermost 4 bits are valid. Other bits are set to zero. |
stickX, stickY |
All 8 bits are valid. |
substickX, substickY |
Uppermost 4 bits are valid. Other bits are set to zero. |
triggerLeft, triggerRight |
Leftmost 4 bits are valid. Other bits are set to zero. |
analogA, analogB |
All 8 bits are valid. |
stickX, stickY |
All 8 bits are valid. |
substickX, substickY |
All 8 bits are valid. |
triggerLeft, triggerRight |
All 8 bits are valid. |
analogA, analogB |
All 8 bits are invalid and set to zero. |
stickX, stickY |
All 8 bits are valid. |
substickX, substickY |
All 8 bits are valid. |
triggerLeft, triggerRight |
All 8 bits are invalid and set to zero. |
analogA, analogB |
All 8 bits are valid. |
Controller Functions, PADClamp, PADInit, PADReset, PADStatus
03/01/2006 Initial version.