summaryrefslogtreecommitdiff
path: root/include/kernel/power.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/kernel/power.h')
-rw-r--r--include/kernel/power.h56
1 files changed, 52 insertions, 4 deletions
diff --git a/include/kernel/power.h b/include/kernel/power.h
index ed797be..b56731b 100644
--- a/include/kernel/power.h
+++ b/include/kernel/power.h
@@ -8,12 +8,24 @@ extern "C" {
#endif
typedef enum ScePowerCallbackType {
- /** indicates the unit is suspending, seems to occur due to inactivity */
- SCE_POWER_CB_SUSPENDING = 0x00010000,
+ /** indicates the power button was pushed, putting the unit into suspend mode */
+ SCE_POWER_CB_POWER_SWITCH = 0x80000000,
+ /** ? screen on after off ? **/
+ SCE_POWER_CB_UNK_1 = 0x00600000,
+ /** ? screen off ? **/
+ SCE_POWER_CB_UNK_2 = 0x00400000,
+ /** indicates the unit has finish resuming from suspend mode */
+ SCE_POWER_CB_RESUME_COMPLETE = 0x00040000,
/** indicates the unit is resuming from suspend mode */
SCE_POWER_CB_RESUMING = 0x00020000,
- /** indicates the unit has finish resuming from suspend mode */
- SCE_POWER_CB_RESUME_COMPLETE = 0x00040000
+ /** indicates the unit is suspending, seems to occur due to inactivity */
+ SCE_POWER_CB_SUSPENDING = 0x00010000,
+ /** indicates the unit is plugged into an AC outlet */
+ SCE_POWER_CB_AC_POWER = 0x00001000,
+ /** indicates the battery is in low state **/
+ SCE_POWER_CB_LOWBATTERY = 0x00000100,
+ /** indicates there is a battery present in the unit **/
+ SCE_POWER_CB_BATTERY_EXIST = 0x00000080
} ScePowerCallbackType;
/* Callbacks */
@@ -154,6 +166,13 @@ int scePowerGetGpuClockFrequency(void);
int scePowerGetGpuXbarClockFrequency(void);
/**
+ * Requests PS Vita to do a soft reset
+ *
+ * @return always 0
+ */
+int scePowerRequestSoftReset(void);
+
+/**
* Requests PS Vita to do a cold reset
*
* @return always 0
@@ -182,6 +201,16 @@ int scePowerRequestSuspend(void);
int scePowerRequestDisplayOff(void);
/**
+ * Set the screen brightness.
+ * @see ::sceAVConfigSetDisplayBrightness for userland counterpart.
+ *
+ * @param brightness Brightness that the screen will be set to (range 21-65536, 0 turns off the screen).
+ *
+ * @return ?
+ */
+int scePowerSetDisplayBrightness(int brightness);
+
+/**
* Sets CPU clock frequency
*
* @param freq - Frequency to set in Mhz
@@ -217,6 +246,25 @@ int scePowerSetGpuClockFrequency(int freq);
*/
int scePowerSetGpuXbarClockFrequency(int freq);
+/**
+ * Sets the time before idle callback is notified.
+ *
+ * @param callback_slot - Callback slot from 0 to 7.
+ * @param time - Time in microseconds.
+ *
+ * @return 0 on success, < 0 on error
+ */
+int scePowerSetIdleTimer(int callback_slot, SceUInt64 time);
+
+/**
+ * Sets the PS button hold time for showing the quick menu.
+ *
+ * @param time - Time in microseconds.
+ *
+ * @return 0 always
+ */
+int scePowerSetPsButtonPushTime(int time);
+
#ifdef __cplusplus
}
#endif