PSP2SDK  dirty-f9e4f2d
The free SDK for PSP2
include/psp2/kernel/processmgr.h
Go to the documentation of this file.
00001 
00012 #ifndef _PSP2_KERNEL_PROCESSMGR_H_
00013 #define _PSP2_KERNEL_PROCESSMGR_H_
00014 
00015 #include <psp2/kernel/threadmgr.h>
00016 #include <psp2/types.h>
00017 
00018 #ifdef __cplusplus
00019 extern "C" {
00020 #endif
00021 
00022 enum {
00023     PSP2_KERNEL_PROCESS_PRIORITY_SYSTEM_HIGH    = 32,
00024     PSP2_KERNEL_PROCESS_PRIORITY_SYSTEM_DEFAULT = 96,
00025     PSP2_KERNEL_PROCESS_PRIORITY_SYSTEM_LOW     = 159
00026 };
00027 
00028 enum {
00029     PSP2_KERNEL_PROCESS_PRIORITY_USER_HIGH      = 64,
00030     PSP2_KERNEL_PROCESS_PRIORITY_USER_DEFAULT   = 96,
00031     PSP2_KERNEL_PROCESS_PRIORITY_USER_LOW       = 127
00032 };
00033 
00034 enum {
00036     PSP2_KERNEL_POWER_TICK_DEFAULT              = 0,
00038     PSP2_KERNEL_POWER_TICK_DISABLE_AUTO_SUSPEND = 1,
00040     PSP2_KERNEL_POWER_TICK_DISABLE_OLED_OFF     = 4,
00042     PSP2_KERNEL_POWER_TICK_DISABLE_OLED_DIMMING = 6
00043 };
00044 
00045 /***
00046  * Exit current Process with specified return code
00047  *
00048  * @param[in] res - Exit code to return
00049  *
00050  * @return 0 on success, < 0 on error.
00051  * @note - If NULL is provided as FrameBuf pointer, output is blacked out.
00052 */
00053 int sceKernelExitProcess(int res);
00054 
00055 /***
00056  * Cancel specified idle timers to prevent entering in power save processing.
00057  *
00058  * @param[in] type - One of ::KernelPowerTickType
00059  *
00060  * @return 0
00061 */
00062 int sceKernelPowerTick(int type);
00063 
00064 /***
00065  * Get the process time of the current process.
00066  *
00067  * @param[out] type - Pointer to a ::SceKernelSysClock structure which will receive the process time.
00068  *
00069  * @return 0 on success, < 0 on error.
00070 */
00071 int sceKernelGetProcessTime(SceKernelSysClock *pSysClock);
00072 
00073 /***
00074  * Get the lower 32 bits part of process time of the current process.
00075  *
00076  * @return process time of the current process
00077 */
00078 SceUInt32 sceKernelGetProcessTimeLow(void);
00079 
00080 /***
00081  * Get the process time of the current process.
00082  *
00083  * @return process time of the current process
00084 */
00085 SceUInt64 sceKernelGetProcessTimeWide(void);
00086 
00087 #ifdef __cplusplus
00088 }
00089 #endif
00090 
00091 #endif /* _PSP2_KERNEL_PROCESSMGR_H_ */
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines