uOFW
Reverse engineered PSP kernel 6.60.
Data Structures | Enumerations | Functions
LED Module

Data Structures

struct  SceLedConfiguration

Enumerations

enum  ScePspLedTypes { PSP_LED_TYPE_MS = 0, PSP_LED_TYPE_WLAN = 1, PSP_LED_TYPE_BT = 2 }
enum  SceLedModes { SCE_LED_MODE_OFF = 0, SCE_LED_MODE_ON = 1, SCE_LED_MODE_BLINK = 2, SCE_LED_MODE_SELECTIVE_EXEC = 3 }
enum  SceLedCmds {
  SCE_LED_CMD_SAVE_CMD = 1, SCE_LED_CMD_EXECUTE_SAVED_CMD = 2, SCE_LED_CMD_REGISTER_CMD = 3, SCE_LED_CMD_EXECUTE_CMD = 4,
  SCE_LED_CMD_TURN_LED_ON = 16, SCE_LED_CMD_TURN_LED_OFF = 17, SCE_LED_CMD_SWITCH_LED_STATE = 18, SCE_LED_CMD_BLINK_LED = 19
}

Functions

u32 sceLedInit (void)
u32 sceLedEnd (void)
s32 sceLedSetMode (s32 led, s32 mode, SceLedConfiguration *config)

Detailed Description

Hardware LED management.


Enumeration Type Documentation

The LEDs which can be controlled via sceLedSetMode().

Enumerator:
PSP_LED_TYPE_MS 

Memory-Stick LED.

PSP_LED_TYPE_WLAN 

W-LAN LED.

PSP_LED_TYPE_BT 

Bluetooth LED.

The possible LED control commands.

Enumerator:
SCE_LED_MODE_OFF 

Turn a LED OFF.

SCE_LED_MODE_ON 

Turn a LED ON.

SCE_LED_MODE_BLINK 

Set a blink event for a LED.

SCE_LED_MODE_SELECTIVE_EXEC 

Register LED configuration commands and execute them. Its use is not recommended, as it is still not completely known how that mode works.

enum SceLedCmds

LED control commands which can be passed via a SceLedConfiguration package to the system.

Enumerator:
SCE_LED_CMD_SAVE_CMD 

Save a LED configuration command for later use. You can only save one configuration.

SCE_LED_CMD_EXECUTE_SAVED_CMD 

Execute a saved LED configuration command.

SCE_LED_CMD_REGISTER_CMD 

Register a LED configuration to be executed manually by the user. Upto 4 LED configuration can be registered the same time.

SCE_LED_CMD_EXECUTE_CMD 

Execute the recently registered LED configuration. Once it has been executed as many times the user decided, the previously registered LED command will be executed.

SCE_LED_CMD_TURN_LED_ON 

Turn ON a specified LED.

SCE_LED_CMD_TURN_LED_OFF 

Turn OFF a specified LED.

SCE_LED_CMD_SWITCH_LED_STATE 

Switch the state of an LED. ON -> OFF, or OFF -> ON.

SCE_LED_CMD_BLINK_LED 

Setup a blink event for a LED. The settings for the blink event are set via the SceLedConfiguration.


Function Documentation

u32 sceLedInit ( void  )

Initialize the LED library, enable the PSP's LEDs and turn them ON.

Returns:
SCE_ERROR_OK.
u32 sceLedEnd ( void  )

Terminate the LED library and disable the PSP's LEDs.

Returns:
SCE_ERROR_OK.
s32 sceLedSetMode ( s32  led,
s32  mode,
SceLedConfiguration config 
)

Set a LED mode.

Parameters:
ledThe LED to set a mode for. One of ScePspLedTypes.
modeThe mode to set for a LED. One of SceLedModes.
configConfiguration settings for a LED. Is only used for the SceLedModes SCE_LED_MODE_BLINK and SCE_LED_MODE_SELECTIVE_EXEC.
Returns:
SCE_ERROR_OK on success.
 All Data Structures Files Variables