11#define MAX_PAD_CODES (64)
12#define MAX_PORT_NUM (7)
13#define MAX_PAD_CAPABILITY_INFO (32)
14#define MAX_PAD_ACTUATOR (2)
16#define PAD_TYPE_STANDARD (0)
17#define PAD_TYPE_REMOTE (4)
18#define PAD_TYPE_LDD (5)
20#define PAD_PRESS_MODE_ON (1)
21#define PAD_PRESS_MODE_OFF (0)
23#define PAD_INFO_SUPPORTED_PRESS_MODE (1)
25#define PAD_SENSOR_MODE_ON (1)
26#define PAD_SENSOR_MODE_OFF (0)
28#define PAD_INFO_SUPPORTED_SENSOR_MODE (1)
30#define PAD_SETTINGS_PRESS_ON (1<<1)
31#define PAD_SETTINGS_PRESS_OFF (0)
32#define PAD_SETTINGS_SENSOR_ON (1<<2)
33#define PAD_SETTINGS_SENSOR_OFF (0)
36#define PAD_CTRL_LEFT (1<<7)
37#define PAD_CTRL_DOWN (1<<6)
38#define PAD_CTRL_RIGHT (1<<5)
39#define PAD_CTRL_UP (1<<4)
40#define PAD_CTRL_START (1<<3)
41#define PAD_CTRL_R3 (1<<2)
42#define PAD_CTRL_L3 (1<<1)
43#define PAD_CTRL_SELECT (1<<0)
46#define PAD_CTRL_SQUARE (1<<7)
47#define PAD_CTRL_CROSS (1<<6)
48#define PAD_CTRL_CIRCLE (1<<5)
49#define PAD_CTRL_TRIANGLE (1<<4)
50#define PAD_CTRL_R1 (1<<3)
51#define PAD_CTRL_L1 (1<<2)
52#define PAD_CTRL_R2 (1<<1)
53#define PAD_CTRL_L2 (1<<0)
56#define PAD_ERROR_FATAL 0x80121101
57#define PAD_ERROR_INVALID_PARAMETER 0x80121102
58#define PAD_ERROR_ALREADY_INITIALIZED 0x80121103
59#define PAD_ERROR_NOT_INITIALIZED 0x80121104
s32 ioPadInfoPressMode(u32 port)
Get pad press mode.
s32 ioPadLddGetPortNo(s32 handle)
Get port number from registered virtual pad handle.
s32 ioPadGetInfo2(padInfo2 *info)
Get pad information (new format).
s32 ioPadLddRegisterController()
Register a new virtual pad.
struct _pad_act_param padActParam
Pad action parameters data structure.
struct _pad_capability_info padCapabilityInfo
Pad capability information data structure. All 1-bit values are 1 when the capability is present,...
s32 ioPadInit(u32 max)
Initialize Pad IO management.
s32 ioPadGetInfo(padInfo *info)
Get pad information.
struct _pad_data padData
Pad data data structure. All 1-bit button fields are zero when inctive, and 1 when active.
enum _io_pad_bd_code ioPadBdCode
BD remote button codes.
s32 ioPadSetPressMode(u32 port, u32 mode)
Set pad press mode.
s32 ioPadEnd()
End of Pad IO management.
s32 ioPadClearBuf(u32 port)
Clear pad buffer.
s32 ioPadInfoSensorMode(u32 port)
Get pad sensor mode.
s32 ioPadPeriphGetData(u32 port, padPeriphData *periphData)
Get pad peripheral data.
enum _io_pad_button_data_offset ioPadButtonDataOffset
struct _pad_info padInfo
Pad info data structure (old format).
u32 ioPadLddDataInsert(s32 handle, padData *data)
Insert pad data into virtual pad.
s32 ioPadLddUnregisterController(s32 handle)
Unregister a virtual pad.
s32 ioPadGetCapabilityInfo(u32 port, padCapabilityInfo *capabilities)
Get pad capability information.
u32 ioPadSetActDirect(u32 port, padActParam *actParam)
Set pad action (rumble) data.
s32 ioPadSetPortSetting(u32 port, u32 setting)
Set pad port setting.
_io_pad_bd_code
BD remote button codes.
s32 ioPadPeriphGetInfo(padPeriphInfo *periphInfo)
Get pad peripheral information.
s32 ioPadGetData(u32 port, padData *data)
Get pad data.
#define MAX_PAD_CAPABILITY_INFO
_io_pad_button_data_offset
@ PAD_BUTTON_OFFSET_ANALOG_RIGHT_X
@ PAD_BUTTON_OFFSET_PRESS_CIRCLE
@ PAD_BUTTON_OFFSET_DIGITAL2
@ PAD_BUTTON_OFFSET_PRESS_L2
@ PAD_BUTTON_OFFSET_DIGITAL1
@ PAD_BUTTON_OFFSET_PRESS_TRIANGLE
@ PAD_BUTTON_OFFSET_PRESS_UP
@ PAD_BUTTON_OFFSET_PRESS_R1
@ PAD_BUTTON_OFFSET_ANALOG_LEFT_Y
@ PAD_BUTTON_OFFSET_ANALOG_RIGHT_Y
@ PAD_BUTTON_OFFSET_PRESS_R2
@ PAD_BUTTON_OFFSET_PRESS_CROSS
@ PAD_BUTTON_OFFSET_SENSOR_G
@ PAD_BUTTON_OFFSET_PRESS_DOWN
@ PAD_BUTTON_OFFSET_PRESS_LEFT
@ PAD_BUTTON_OFFSET_PRESS_RIGHT
@ PAD_BUTTON_OFFSET_SENSOR_Y
@ PAD_BUTTON_OFFSET_PRESS_L1
@ PAD_BUTTON_OFFSET_SENSOR_Z
@ PAD_BUTTON_OFFSET_ANALOG_LEFT_X
@ PAD_BUTTON_OFFSET_PRESS_SQUARE
@ PAD_BUTTON_OFFSET_SENSOR_X
struct _pad_periph_info padPeriphInfo
Pad peripheral information data structure.
struct _pad_periph_data padPeriphData
Pad peripheral data data structure.
struct _pad_info2 padInfo2
Pad info data structure (new format).
s32 ioPadSetSensorMode(u32 port, u32 mode)
Set pad sensor mode.
s32 ioPadGetDataExtra(u32 port, u32 *type, padData *data)
Get pad data.
Pad action parameters data structure.
u8 small_motor
Small Motor parameter 0: OFF, 1: On.
u8 large_motor
Large Motor 0: OFF, 1-255: Motor Speed, higher == faster.
u8 motor[(2)]
All motors statuses.
Pad capability information data structure. All 1-bit values are 1 when the capability is present,...
unsigned int ps3spec
controller meets ps3 specifications
unsigned int has_vibrate
controller has inbuilt vibration motor
unsigned int has_hps
controller has high precision stick
unsigned int has_pressure
controller has pressure-sensitive buttons
unsigned int has_sensors
controller has sensors, e.g. sixaxis, X,Y,Z,G
u32 reserved[(32) -1]
reserved
u32 info[(32)]
The whole capabilities in an array of 32-bit integers.
Pad data data structure. All 1-bit button fields are zero when inctive, and 1 when active.
unsigned int BTN_RIGHT
right button
unsigned int ANA_L_V
left analog nub vertical position (0x0000 - 0x00FF)
unsigned int PRE_L1
L1 button pressure information (0x0000 - 0x00FF)
unsigned int SENSOR_Z
Z sensor information (0x0000 - 0x03FF)
unsigned int BTN_R1
R1 button.
unsigned int BTN_LEFT
left button
unsigned int BTN_L3
L3 button.
unsigned int ANA_L_H
left analog nub horizontal position (0x0000 - 0x00FF)
unsigned int seven
always 0x7
unsigned int SENSOR_Y
Y sensor information (0x0000 - 0x03FF)
unsigned int BTN_CROSS
cross button
unsigned int BTN_BDCODE
BD remote len information.
unsigned int BTN_R3
R3 button.
unsigned int PRE_R2
R2 button pressure information (0x0000 - 0x00FF)
unsigned int PRE_L2
L2 button pressure information (0x0000 - 0x00FF)
unsigned int PRE_R1
R1 button pressure information (0x0000 - 0x00FF)
unsigned int BTN_UP
up button
unsigned int SENSOR_X
X sensor information (0x0000 - 0x03FF)
unsigned int PRE_LEFT
left button pressure information (0x0000 - 0x00FF)
unsigned int BTN_DOWN
down button
unsigned int SENSOR_G
G sensor information (0x0000 - 0x03FF)
unsigned int BTN_CIRCLE
circle button
unsigned int BTN_L1
L1 button.
unsigned int BTN_R2
R2 button.
unsigned int PRE_DOWN
down button pressure information (0x0000 - 0x00FF)
unsigned int BTN_SELECT
select button
unsigned int ANA_R_H
right analog nub horizontal position (0x0000 - 0x00FF)
unsigned int BTN_START
start button
unsigned int halflen
len/2
unsigned int PRE_TRIANGLE
triangle button pressure information (0x0000 - 0x00FF)
u8 reserved[76]
BD remote code information see ioPadBdCode for values.
u16 button[(64)]
array of button values
unsigned int BTN_L2
L2 button.
unsigned int BTN_TRIANGLE
triangle button
unsigned int PRE_RIGHT
right button pressure information (0x0000 - 0x00FF)
unsigned int BTN_SQUARE
square button
unsigned int PRE_CIRCLE
circle button pressure information (0x0000 - 0x00FF)
unsigned int PRE_SQUARE
square button pressure information (0x0000 - 0x00FF)
unsigned int PRE_UP
up button pressure information (0x0000 - 0x00FF)
unsigned int ANA_R_V
right analog nub vertical position (0x0000 - 0x00FF)
unsigned int PRE_CROSS
cross button pressure information (0x0000 - 0x00FF)
Pad info data structure (new format).
u32 max
max pads allowed to connect
u32 device_type[(7)]
0: Standard, 4: Bluray Remote, 5: LDD
u32 connected
how many pads connected
u32 port_setting[(7)]
Bit 1: Pressure sensitivity turned on, Bit 2: Sensors turned on.
u32 port_status[(7)]
Bit 0: Connected (0: Disconnected, 1: Connected), Bit 1: assign changes?
u32 info
Bit 0 lets the system intercept pad? other bits are reserved.
u32 device_capability[(7)]
See: PadCapabilityInfo. Bit 0: PS3SPEC, Bit 1: has_pressure, Bit 2: has_sensor, Bit 3: has_hps,...
Pad info data structure (old format).
u16 vendor_id[(127)]
array of vendor ids
u32 connected
how many pads connected
u32 info
bit 0 lets the system intercept pad? other bits are reserved
u32 max
max pads allowed to connect
u16 product_id[(127)]
array of product ids
u8 status[(127)]
array of pad statuses
Pad peripheral data data structure.
u32 pclass_type
Pad class type.
s32 len
Length of button array.
u32 pclass_profile
Pas class profile.
u16 button[(64)]
Button array.
Pad peripheral information data structure.
u32 max
max pads allowed to connect
u32 info
bit 0 lets the system intercept pad? other bits are reserved
u32 connected
how many pads connected
u32 device_capability[(7)]
Pad capability.
u32 port_status[(7)]
Bit 0: Connected (0: Disconnected, 1: Connected), Bit 1: assign changes?
u32 pclass_profile[(7)]
Pad class profile.
u32 device_type[(7)]
0: Standard, 4: Bluray Remote, 5: LDD
u32 pclass_type[(7)]
Pad class type.
u32 port_setting[(7)]
Bit 1: Pressure sensitivity turned on, Bit 2: Sensors turned on.