PICO Unity XR SDK
PXR_System Class Reference

Static Public Member Functions

static void InitSystemService (string objectName)
 Initializes the system service for a specified game object. Must be called before calling other system related functions. More...
 
static void BindSystemService ()
 Binds the system service. Must be called before calling other system related functions.
 
static void UnBindSystemService ()
 Unbinds the system service.
 
static bool StartBatteryReceiver (string objName)
 Turns on the battery service. More...
 
static bool StopBatteryReceiver ()
 Turns off the battery service. More...
 
static bool SetCommonBrightness (int brightness)
 Sets the brightness for the current HMD. More...
 
static int GetCommonBrightness ()
 Gets the brightness of the current HMD. More...
 
static int[] GetScreenBrightnessLevel ()
 Gets the brightness level of the current screen. More...
 
static void SetScreenBrightnessLevel (int brightness, int level)
 Sets a brightness level for the current screen. More...
 
static bool InitAudioDevice ()
 Initializes the audio device. More...
 
static bool StartAudioReceiver (string objName)
 Turns on the volume service for a specified game object. More...
 
static bool StopAudioReceiver ()
 Turns off the volume service. More...
 
static int GetMaxVolumeNumber ()
 Gets the maximum volume. Call InitAudioDevice to initialize the audio device before calling this function. More...
 
static int GetCurrentVolumeNumber ()
 Gets the current volume. Call InitAudioDevice to initialize the audio device before calling this function. More...
 
static bool VolumeUp ()
 Increases the volume. Call InitAudioDevice to initialize the audio device before calling this function. More...
 
static bool VolumeDown ()
 Decreases the volume. Call InitAudioDevice to initialize the audio device before calling this function. More...
 
static bool SetVolumeNum (int volume)
 Sets the volume. Call InitAudioDevice to initialize the audio device before calling this function. More...
 
static PXR_PlatformSetting.simulationType IsCurrentDeviceValid ()
 Checks whether the current device has valid permission for the game. More...
 
static bool AppEntitlementCheck (string appid)
 Uses the appID to get whether the entitlement required by an app is present. More...
 
static bool KeyEntitlementCheck (string publicKey)
 Uses the publicKey to get the entitlement check result. More...
 
static int AppEntitlementCheckExtra (string appId)
 Use the appID to get the error code of the entitlement check result. More...
 
static int KeyEntitlementCheckExtra (string publicKey)
 Use the publicKey to get the error code of the entitlement check result. More...
 
static string GetSDKVersion ()
 Gets the SDK version. More...
 
static double GetPredictedDisplayTime ()
 Gets the predicted time a frame will be displayed after being rendered. More...
 
static bool SetExtraLatencyMode (int mode)
 Sets the extra latency mode. Note: Call this function once only. More...
 
static string StateGetDeviceInfo (SystemInfoEnum type)
 Gets the specified type of device information. More...
 
static void ControlSetDeviceAction (DeviceControlEnum deviceControl, Action< int > callback)
 Controls the device to shut down or reboot. More...
 
static void ControlAPPManager (PackageControlEnum packageControl, string path, Action< int > callback)
 Installs or uninstalls app silently. More...
 
static void ControlSetAutoConnectWIFI (string ssid, string pwd, Action< bool > callback)
 Sets a Wi-Fi that the device is automatically connected to. More...
 
static void ControlClearAutoConnectWIFI (Action< bool > callback)
 Removes the Wi-Fi that the device is automatically connected to. More...
 
static void PropertySetHomeKey (HomeEventEnum eventEnum, HomeFunctionEnum function, Action< bool > callback)
 Sets the Home key event. More...
 
static void PropertySetHomeKeyAll (HomeEventEnum eventEnum, HomeFunctionEnum function, int timesetup, string pkg, string className, Action< bool > callback)
 Sets extended settings for the Home key. More...
 
static void PropertyDisablePowerKey (bool isSingleTap, bool enable, Action< int > callback)
 Sets the Power key event. More...
 
static void PropertySetScreenOffDelay (ScreenOffDelayTimeEnum timeEnum, Action< int > callback)
 Sets the time the screen turns off when the device is not in use. More...
 
static void PropertySetSleepDelay (SleepDelayTimeEnum timeEnum)
 Sets the time the system sleeps when the device is not in use. More...
 
static void SwitchSystemFunction (SystemFunctionSwitchEnum systemFunction, SwitchEnum switchEnum)
 Switches specified system function on/off. More...
 
static void SwitchSetUsbConfigurationOption (USBConfigModeEnum uSBConfigModeEnum)
 Sets the USB mode. More...
 
static void ScreenOn ()
 Turns the screen on. More...
 
static void ScreenOff ()
 Turns the screen off. More...
 
static void AcquireWakeLock ()
 Acquires the wake lock.
 
static void ReleaseWakeLock ()
 Releases the wake lock.
 
static void EnableEnterKey ()
 Enables the Confirm key.
 
static void DisableEnterKey ()
 Disables the Confirm key.
 
static void EnableVolumeKey ()
 Enables the Volume Key.
 
static void DisableVolumeKey ()
 Disables the Volume Key.
 
static void EnableBackKey ()
 Enables the Back Key.
 
static void DisableBackKey ()
 Disables the Back Key.
 
static void WriteConfigFileToDataLocal (string path, string content, Action< bool > callback)
 Writes the configuration file to the /data/local/tmp/ path. More...
 
static void ResetAllKeyToDefault (Action< bool > callback)
 Resets all keys to default configuration. More...
 
static void SetAPPAsHome (SwitchEnum switchEnum, string packageName)
 Sets an app as the launcher app. More...
 
static void KillAppsByPidOrPackageName (int[] pids, string[] packageNames)
 Force quits app(s) by passing app PID or package name. More...
 
static void KillBackgroundAppsWithWhiteList (string[] packageNames)
 Force quits background app(s) expect those in the allowlist. More...
 
static void FreezeScreen (bool freeze)
 Freezes the screen to the front. The screen will turn around with the HMD. Note: This function only supports G2 4K series. More...
 
static void OpenMiracast ()
 Turns on the screencast function.
 
static bool IsMiracastOn ()
 Gets the status of the screencast function. More...
 
static void CloseMiracast ()
 Turns off the screencast function.
 
static void StartScan ()
 Starts scanning for devices that can be used for screen casting.
 
static void StopScan ()
 Stops scanning for devices that can be used for screen casting.
 
static void ConnectWifiDisplay (string modelJson)
 Casts the screen to the specified device. More...
 
static void DisConnectWifiDisplay ()
 Stops casting the screen to the current device.
 
static void ForgetWifiDisplay (string address)
 Forgets the device that have been connected for screencast. More...
 
static void RenameWifiDisplay (string address, string newName)
 Renames the device connected for screencast (only the name for local storage). More...
 
static void SetWDModelsCallback ()
 Returns a wdmodel list of the device(s) for screencast.
 
static void SetWDJsonCallback ()
 Returns a JSON array of the device(s) for screencast.
 
static void UpdateWifiDisplays (Action< string > callback)
 Manually updates the device list for screencast. More...
 
static string GetConnectedWD ()
 Gets the information of the current connected device. More...
 
static void SwitchLargeSpaceScene (bool open, Action< bool > callback)
 Switches the large space scene on. More...
 
static void GetSwitchLargeSpaceStatus (Action< string > callback)
 Gets the status of the large space scene. More...
 
static bool SaveLargeSpaceMaps ()
 Saves the large space map. More...
 
static void ExportMaps (Action< bool > callback)
 Exports map(s). More...
 
static void ImportMaps (Action< bool > callback)
 Imports map(s). More...
 
static int GetSensorStatus ()
 Gets the sensor's status. More...
 
static void SetSystemDisplayFrequency (float rate)
 Sets the system display frequency rate. More...
 
static float GetSystemDisplayFrequency ()
 Gets the system display frequency rate. More...
 
static int GetPredictedMainSensorStateNew (ref PxrSensorState2 sensorState, ref int sensorFrameIndex)
 Gets the predicted status of the sensor. More...
 
static int ContentProtect (int data)
 
static float[] GetCpuUsages ()
 Gets the CPU utilization of the current device. More...
 
static float[] GetDeviceTemperatures (int type, int source)
 Gets device temperature in Celsius. More...
 
static void Capture ()
 Captures the current screen.
 
static void Record ()
 Records the screen. Call this function again to stop recording.
 
static void ControlSetAutoConnectWIFIWithErrorCodeCallback (String ssid, String pwd, int ext, Action< int > callback)
 Connects the device to a specified Wi-Fi.
More...
 
static void AppKeepAlive (String appPackageName, bool keepAlive, int ext)
 Keeps an app active. In other words, improves the priority of an app, thereby making the system not to force quit the app. More...
 
static void EnableFaceTracking (bool enable)
 Enables/disables face tracking. More...
 
static void EnableLipSync (bool enable)
 Enables/disables lipsync. More...
 
static void GetFaceTrackingData (Int64 ts, GetDataType flags, ref PxrFaceTrackingInfo faceTrackingInfo)
 Gets face tracking data. More...
 
static void TimingStartup (int year, int month, int day, int hour, int minute, bool open)
 Schedules auto startup for the device. Note: Supported by PICO Neo3 series. More...
 
static void TimingShutdown (int year, int month, int day, int hour, int minute, bool open)
 Schedules auto shutdown for the device. Note: Supported by PICO Neo3 series. More...
 
static void StartVrSettingsItem (StartVRSettingsEnum settingsEnum, bool hideOtherItem, int ext)
 Displays a specified settings screen. Note: Supported by PICO Neo3 and PICO 4 series. More...
 
static void SwitchVolumeToHomeAndEnter (SwitchEnum switchEnum, int ext)
 Changes the Volume key's function to that of the Home and Enter key's, or restores the volume adjustment function to the Volume key. More...
 
static SwitchEnum IsVolumeChangeToHomeAndEnter ()
 Gets whether the Volume key's function has been changed to that of the Home and Enter key's. More...
 
static int InstallOTAPackage (String otaPackagePath)
 Upgrades the OTA. More...
 
static string GetAutoConnectWiFiConfig ()
 Gets the configuration of the Wi-Fi nerwork that the device automatically connnects to. More...
 
static string GetTimingStartupStatus ()
 Gets the scheduled auto startup settings for the device. More...
 
static string GetTimingShutdownStatus ()
 Gets the scheduled auto shutdown settings for the device. More...
 
static int GetControllerKeyState (ControllerKeyEnum pxrControllerKey)
 Gets the status of a specified controller key. More...
 
static SwitchEnum GetPowerOffWithUSBCable ()
 Gets the status of the switch for setting whether to power off the USB cable when the device is shut down. More...
 
static ScreenOffDelayTimeEnum GetScreenOffDelay ()
 Gets the screen timeout setting for the device. More...
 
static SleepDelayTimeEnum GetSleepDelay ()
 Gets the sleep timeout settings for the device. More...
 
static string GetPowerKeyStatus ()
 Gets the Power key's settings. More...
 
static int GetEnterKeyStatus ()
 Get the Enter key's status. More...
 
static int GetVolumeKeyStatus ()
 Get the Volume key's status. More...
 
static int GetBackKeyStatus ()
 Get the Back key's status. More...
 
static string GetHomKeyStatus (HomeEventEnum homeEvent)
 Gets the event setting for the Home key. More...
 
static void GetSwitchSystemFunctionStatus (SystemFunctionSwitchEnum systemFunction, Action< int > callback)
 Gets the status of a specified system function switch. More...
 
static string GetUsbConfigurationOption ()
 Gets the configured USB mode. More...
 
static string GetCurrentLauncher ()
 Gets the current launcher. More...
 
static int PICOCastInit (Action< int > callback)
 Initializes the screencast service. More...
 
static int PICOCastSetShowAuthorization (int authZ)
 Sets whether to show the screencast authorization window. More...
 
static int PICOCastGetShowAuthorization ()
 Gets the setting of whether to show the screencast authorization window. More...
 
static string PICOCastGetUrl (PICOCastUrlTypeEnum urlType)
 Gets the URL for screencast. More...
 
static int PICOCastStopCast ()
 Stops screencast. More...
 
static int PICOCastSetOption (PICOCastOptionOrStatusEnum castOptionOrStatus, PICOCastOptionValueEnum castOptionValue)
 sets screencast-related properties. More...
 
static PICOCastOptionValueEnum PICOCastGetOptionOrStatus (PICOCastOptionOrStatusEnum castOptionOrStatus)
 Gets the screencast-related property setting for the current device. More...
 
static void SetControllerPairTime (ControllerPairTimeEnum timeEnum, Action< int > callback)
 Sets the duration after which the controllers enter the pairing mode. More...
 
static void GetControllerPairTime (Action< int > callback)
 Gets the duration after which the controllers enter the pairing mode. More...
 
static int SetSystemLanguage (String language)
 Sets the system language for the device. For a language that is spoken in different countries/regions, the system language is then co-set by the language code and the device's country/region code. For example, if the lanaguage code is set to en and the device's country/region code is US, the system language will be set to English (United States). More...
 
static String GetSystemLanguage ()
 Gets the device's system language. More...
 
static int ConfigWifi (String ssid, String pwd)
 Sets a default Wi-Fi network for the device. Once set, the device will automatically connect to the Wi-Fi network if accessible. More...
 
static String[] GetConfiguredWifi ()
 Gets the device's default Wi-Fi network. More...
 
static int SetSystemCountryCode (String countryCode, Action< int > callback)
 Sets a country/region for the device. More...
 
static string GetSystemCountryCode ()
 Gets the device's country/region code. More...
 
static int SetSkipInitSettingPage (int flag)
 Sets the page to skip in initialization settings. More...
 
static int GetSkipInitSettingPage ()
 Gets the page to skip in initialization settings. More...
 
static int IsInitSettingComplete ()
 Gets whether the initialization settings have been complete. More...
 
static int StartActivity (String packageName, String className, String action, String extra, String[] categories, int[] flags)
 Starts an activity in another app. More...
 
static int SetPerformanceLevels (PxrPerfSettings which, PxrSettingsLevel level)
 Sets a GPU or CPU level for the device. More...
 
static PxrSettingsLevel GetPerformanceLevels (PxrPerfSettings which)
 Gets the device's GPU or CPU level. More...
 
static int SetEyeFOV (EyeType eye, float fovLeft, float fovRight, float fovUp, float fovDown)
 Sets FOV in four directions (left, right, up, and down) for specified eye(s). More...
 
static int CustomizeAppLibrary (String[] packageNames, SwitchEnum switchEnum)
 Shows/hides specified app(s) in the library. More...
 
static int GetControllerConnectState ()
 Gets the controller connectivity status. More...
 
static int[] GetControllerBattery ()
 Gets the controller battery level. More...
 
static string GetAppLibraryHideList ()
 Gets the apps that are hidden in the library. More...
 

Member Function Documentation

◆ InitSystemService()

static void InitSystemService ( string  objectName)
static

Initializes the system service for a specified game object. Must be called before calling other system related functions.

Parameters
objectNameThe name of the game object to initialize the system service for.

◆ StartBatteryReceiver()

static bool StartBatteryReceiver ( string  objName)
static

Turns on the battery service.

Parameters
objNameThe name of the game object to turn on the battery service for.
Returns
Whether the power service has been turned on:
  • true: success
  • false: failure

◆ StopBatteryReceiver()

static bool StopBatteryReceiver ( )
static

Turns off the battery service.

Returns
Whether the power service has been turned off:
  • true: success
  • false: failure

◆ SetCommonBrightness()

static bool SetCommonBrightness ( int  brightness)
static

Sets the brightness for the current HMD.

Parameters
brightnessTarget brightness. The valid value ranges from 0 to 255.
Returns
Whether the brightness has been set successfully:
  • true: success
  • false: failure

◆ GetCommonBrightness()

static int GetCommonBrightness ( )
static

Gets the brightness of the current HMD.

Returns
An int value that indicates the brightness. The value ranges from 0 to 255.

◆ GetScreenBrightnessLevel()

static int[] GetScreenBrightnessLevel ( )
static

Gets the brightness level of the current screen.

Returns
An int array. The first bit is the total brightness level supported, the second bit is the current brightness level, and it is the interval value of the brightness level from the third bit to the end bit.

◆ SetScreenBrightnessLevel()

static void SetScreenBrightnessLevel ( int  brightness,
int  level 
)
static

Sets a brightness level for the current screen.

Parameters
brightnessBrightness mode:
  • 0: system default brightness setting
  • 1: custom brightness setting
levelBrightness level. The valid value ranges from 1 to 255. If brightness is set to 1, set a desired brightness level; if brightness is set to 0, the system default brightness setting is adopted.

◆ InitAudioDevice()

static bool InitAudioDevice ( )
static

Initializes the audio device.

Returns
Whether the audio device has been initialized:
  • true: success
  • false: failure

◆ StartAudioReceiver()

static bool StartAudioReceiver ( string  objName)
static

Turns on the volume service for a specified game object.

Parameters
objNameThe name of the game object to turn on the volume service for.
Returns
Whether the volume service has been turned on:
  • true: success
  • false: failure

◆ StopAudioReceiver()

static bool StopAudioReceiver ( )
static

Turns off the volume service.

Returns
Whether the volume service has been turned off:
  • true: success
  • false: failure

◆ GetMaxVolumeNumber()

static int GetMaxVolumeNumber ( )
static

Gets the maximum volume. Call InitAudioDevice to initialize the audio device before calling this function.

Returns
An int value that indicates the maximum volume.

◆ GetCurrentVolumeNumber()

static int GetCurrentVolumeNumber ( )
static

Gets the current volume. Call InitAudioDevice to initialize the audio device before calling this function.

Returns
An int value that indicates the current volume. The value ranges from 0 to 15.

◆ VolumeUp()

static bool VolumeUp ( )
static

Increases the volume. Call InitAudioDevice to initialize the audio device before calling this function.

Returns
Whether the volume has been increased:
  • true: success
  • false: failure

◆ VolumeDown()

static bool VolumeDown ( )
static

Decreases the volume. Call InitAudioDevice to initialize the audio device before calling this function.

Returns
Whether the volume has been decreased:
  • true: success
  • false: failure

◆ SetVolumeNum()

static bool SetVolumeNum ( int  volume)
static

Sets the volume. Call InitAudioDevice to initialize the audio device before calling this function.

Parameters
volumeThe target volume. The valid value ranges from 0 to 15.
Returns
Whether the target volume has been set:
  • true: success
  • false: failure

◆ IsCurrentDeviceValid()

static PXR_PlatformSetting.simulationType IsCurrentDeviceValid ( )
static

Checks whether the current device has valid permission for the game.

Returns
Whether the permission is valid:
  • Null
  • Invalid
  • Valid

◆ AppEntitlementCheck()

static bool AppEntitlementCheck ( string  appid)
static

Uses the appID to get whether the entitlement required by an app is present.

Parameters
appidThe appID.
Returns
Whether the entitlement required by the app is present:
  • true: success
  • false: failure

◆ KeyEntitlementCheck()

static bool KeyEntitlementCheck ( string  publicKey)
static

Uses the publicKey to get the entitlement check result.

Parameters
publicKeyThe publickey.
Returns
The entitlement check result:
  • true: success
  • false: failure

◆ AppEntitlementCheckExtra()

static int AppEntitlementCheckExtra ( string  appId)
static

Use the appID to get the error code of the entitlement check result.

Parameters
appIdThe appID.
Returns
The entitlement check result:
  • -3: timeout
  • -2: service not exist (old versions of ROM have no service. If the app needs to be limited to operating in old versions, this state needs processing)
  • -1: invalid parameter
  • 0: success

◆ KeyEntitlementCheckExtra()

static int KeyEntitlementCheckExtra ( string  publicKey)
static

Use the publicKey to get the error code of the entitlement check result.

Parameters
publicKeyThe publickey.
Returns
The entitlement check result:
  • -3: timeout
  • -2: service not exist (old versions of ROM have no Service. If the app needs to be limited to operating in old versions, this state needs processing)
  • -1: invalid parameter
  • 0: success

◆ GetSDKVersion()

static string GetSDKVersion ( )
static

Gets the SDK version.

Returns
The SDK version.

◆ GetPredictedDisplayTime()

static double GetPredictedDisplayTime ( )
static

Gets the predicted time a frame will be displayed after being rendered.

Returns
The predicted time (in miliseconds).

◆ SetExtraLatencyMode()

static bool SetExtraLatencyMode ( int  mode)
static

Sets the extra latency mode. Note: Call this function once only.

Parameters
modeThe latency mode:
  • 0: ExtraLatencyModeOff (Disable ExtraLatencyMode mode. This option will display the latest rendered frame for display)
  • 1: ExtraLatencyModeOn (Enable ExtraLatencyMode mode. This option will display one frame prior to the latest rendered frame)
  • 2: ExtraLatencyModeDynamic (Use system default setup)
Returns
Whether the extra latency mode has been set:
  • true: success
  • false: failure

◆ StateGetDeviceInfo()

static string StateGetDeviceInfo ( SystemInfoEnum  type)
static

Gets the specified type of device information.

Parameters
typeThe target informaiton type. Enumerations:
  • ELECTRIC_QUANTITY: battery
  • PUI_VERSION: PUI version
  • EQUIPMENT_MODEL: device model
  • EQUIPMENT_SN: device SN code
  • CUSTOMER_SN: customer SN code
  • INTERNAL_STORAGE_SPACE_OF_THE_DEVICE: device storage
  • DEVICE_BLUETOOTH_STATUS: bluetooth status
  • BLUETOOTH_NAME_CONNECTED: bluetooth name
  • BLUETOOTH_MAC_ADDRESS: bluetooth MAC address
  • DEVICE_WIFI_STATUS: Wi-Fi connection status
  • WIFI_NAME_CONNECTED: connected Wi-Fi name
  • WLAN_MAC_ADDRESS: WLAN MAC address
  • DEVICE_IP: device IP address
  • CHARGING_STATUS: device charging status
Returns
The specified type of device information. For CHARGING_STATUS, an int value will be returned: 2-charging; 3-not charging.

◆ ControlSetDeviceAction()

static void ControlSetDeviceAction ( DeviceControlEnum  deviceControl,
Action< int >  callback 
)
static

Controls the device to shut down or reboot.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.
Parameters
deviceControlDevice action. Enumerations:
  • DEVICE_CONTROL_REBOOT
  • DEVICE_CONTROL_SHUTDOWN
callbackCallback:
  • 1: failed to shut down or reboot the device
  • 2: no permission for device control

◆ ControlAPPManager()

static void ControlAPPManager ( PackageControlEnum  packageControl,
string  path,
Action< int >  callback 
)
static

Installs or uninstalls app silently.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.
Parameters
packageControlThe action. Enumerations:
  • PACKAGE_SILENCE_INSTALL: silent installation
  • PACKAGE_SILENCE_UNINSTALL: silent uninstallation
pathThe path to the app package for silent installation or the name of the app package for silent uninstallation.
callbackCallback:
  • 0: success
  • 1: failure
  • 2: no permission for this operation

◆ ControlSetAutoConnectWIFI()

static void ControlSetAutoConnectWIFI ( string  ssid,
string  pwd,
Action< bool >  callback 
)
static

Sets a Wi-Fi that the device is automatically connected to.

Parameters
ssidWi-Fi name.
pwdWi-Fi password.
callbackCallback:
  • true: connected
  • false: failed to connect

◆ ControlClearAutoConnectWIFI()

static void ControlClearAutoConnectWIFI ( Action< bool >  callback)
static

Removes the Wi-Fi that the device is automatically connected to.

Parameters
callbackCallback:
  • true: removed
  • false: failed to remove

◆ PropertySetHomeKey()

static void PropertySetHomeKey ( HomeEventEnum  eventEnum,
HomeFunctionEnum  function,
Action< bool >  callback 
)
static

Sets the Home key event.

Parameters
eventEnumTarget event. Enumerations:
  • SINGLE_CLICK: a single-click event
  • DOUBLE_CLICK: a double-click event
functionThe function of the event. Enumerations:
  • VALUE_HOME_GO_TO_SETTING: go to Settings
  • VALUE_HOME_RECENTER: recenter
  • VALUE_HOME_DISABLE: disable Home key event
  • VALUE_HOME_GO_TO_HOME: open the launcher
callbackCallback:
  • true: set
  • false: failed to set

◆ PropertySetHomeKeyAll()

static void PropertySetHomeKeyAll ( HomeEventEnum  eventEnum,
HomeFunctionEnum  function,
int  timesetup,
string  pkg,
string  className,
Action< bool >  callback 
)
static

Sets extended settings for the Home key.

Parameters
eventEnumTarget event. Enumerations:
  • SINGLE_CLICK: a single-click event
  • DOUBLE_CLICK: a double-click event
functionThe function of the event. Enumerations:
  • VALUE_HOME_GO_TO_SETTING: go to Settings
  • VALUE_HOME_RECENTER: recenter
  • VALUE_HOME_DISABLE: disable Home key event
  • VALUE_HOME_GO_TO_HOME: open the launcher
timesetupThe interval of key pressing is set only if there is the double click event or long pressing event. When shortly pressing the Home key, pass 0.
pkgPass null.
classNamePass null.
callbackCallback:
  • true: set
  • false: failed to set

◆ PropertyDisablePowerKey()

static void PropertyDisablePowerKey ( bool  isSingleTap,
bool  enable,
Action< int >  callback 
)
static

Sets the Power key event.

Parameters
isSingleTapWhether it is a single click event:
  • true: single-click event
  • false: long-press event
enableKey enabling status:
  • true: enabled
  • false: not enabled
callbackCallback:
  • 0: set
  • 1: failed to set
  • 11: press the Power key for no more than 5s

◆ PropertySetScreenOffDelay()

static void PropertySetScreenOffDelay ( ScreenOffDelayTimeEnum  timeEnum,
Action< int >  callback 
)
static

Sets the time the screen turns off when the device is not in use.

Parameters
timeEnumScreen off timeout. Enumerations:
  • Never: never off
  • THREE: 3s
  • TEN: 10s
  • THIRTY: 30s
  • SIXTY: 60s
  • THREE_HUNDRED: 5 mins
  • SIX_HUNDRED: 10 mins
callbackCallback:
  • 0: set
  • 1: failed to set
  • 10: the screen off timeout should not be greater than the system sleep timeout

◆ PropertySetSleepDelay()

static void PropertySetSleepDelay ( SleepDelayTimeEnum  timeEnum)
static

Sets the time the system sleeps when the device is not in use.

Parameters
timeEnumSystem sleep timeout. Enumerations:
  • Never: never sleep
  • FIFTEEN: 15s
  • THIRTY: 30s
  • SIXTY: 60s
  • THREE_HUNDRED: 5 mins
  • SIX_HUNDRED: 10 mins
  • ONE_THOUSAND_AND_EIGHT_HUNDRED: 30 mins

◆ SwitchSystemFunction()

static void SwitchSystemFunction ( SystemFunctionSwitchEnum  systemFunction,
SwitchEnum  switchEnum 
)
static

Switches specified system function on/off.

Parameters
systemFunctionFunction name. Enumerations:
  • SFS_USB: USB debugging
  • SFS_AUTOSLEEP: auto sleep
  • SFS_SCREENON_CHARGING: screen-on charging
  • SFS_OTG_CHARGING: OTG charging
  • SFS_RETURN_MENU_IN_2DMODE: display the Return icon on the 2D screen
  • SFS_COMBINATION_KEY: combination key
  • SFS_CALIBRATION_WITH_POWER_ON: calibration with power on
  • SFS_SYSTEM_UPDATE: system update
  • SFS_CAST_SERVICE: phone casting service
  • SFS_EYE_PROTECTION: eye-protection mode
  • SFS_SECURITY_ZONE_PERMANENTLY: permanently disable the 6DoF play area
  • SFS_Auto_Calibration: auto recenter/recalibrate
  • SFS_USB_BOOT: USB plug-in boot
  • SFS_VOLUME_UI: global volume UI
  • SFS_CONTROLLER_UI: global controller connected UI
  • SFS_NAVGATION_SWITCH: navigation bar
  • SFS_SHORTCUT_SHOW_RECORD_UI: screen recording button UI
  • SFS_SHORTCUT_SHOW_FIT_UI: PICO fit UI
  • SFS_SHORTCUT_SHOW_CAST_UI: screencast button UI
  • SFS_SHORTCUT_SHOW_CAPTURE_UI: screenshot button UI
  • SFS_USB_FORCE_HOST: set the Neo3 device as the host device
  • SFS_SET_DEFAULT_SAFETY_ZONE: set a default play area for a Neo3 device
  • SFS_ALLOW_RESET_BOUNDARY: allow to reset customized boundary
  • SFS_BOUNDARY_CONFIRMATION_SCREEN: whether to display the boundary confirmation screen
  • SFS_LONG_PRESS_HOME_TO_RECENTER: long press the Home key to recenter
  • SFS_POWER_CTRL_WIFI_ENABLE: Neo3 device stays connected to the network when the device sleeps/turns off
  • SFS_WIFI_DISABLE: disable Wi-Fi for Neo3 device
  • SFS_SIX_DOF_SWITCH: 6DoF position tracking
  • SFS_INVERSE_DISPERSION: anti-dispersion (need to restart the device to make the setting take effect)
  • PBS_SystemFunctionSwitchEnum.SFS_LOGCAT: system log switch (/data/logs)
  • PBS_SystemFunctionSwitchEnum.SFS_PSENSOR: PSensor switch (need to restart the device to make the setting take effect)
  • PBS_SystemFunctionSwitchEnum.SFS_SYSTEM_UPDATE_OTA: OTA upgrade
  • PBS_SystemFunctionSwitchEnum.SFS_SYSTEM_UPDATE_APP: app upgrade and update
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_WLAN_UI: quickly set whether to show the WLAN button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_BOUNDARY_UI: quickly set whether to show the boundary button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_BLUETOOTH_UI: quickly set whether to show the bluetooth button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_CLEAN_TASK_UI: quickly set whether to show the one-click clear button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI: quickly set whether to show the IPD adjustment button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_POWER_UI: quickly set whether to show the power button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_EDIT_UI: quickly set whether to show the edit button
  • PBS_SystemFunctionSwitchEnum.SFS_BASIC_SETTING_APP_LIBRARY_UI: the button for customizing the app library
  • PBS_SystemFunctionSwitchEnum.SFS_BASIC_SETTING_SHORTCUT_UI: the button for customizing quick settings
switchEnumWhether to switch the function on/off:
  • S_ON: switch on
  • S_OFF: switch off

◆ SwitchSetUsbConfigurationOption()

static void SwitchSetUsbConfigurationOption ( USBConfigModeEnum  uSBConfigModeEnum)
static

Sets the USB mode.

Parameters
uSBConfigModeEnumUSB configuration mode. Enumerations:
  • MTP: MTP mode
  • CHARGE: charging mode

◆ ScreenOn()

static void ScreenOn ( )
static

Turns the screen on.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.

◆ ScreenOff()

static void ScreenOff ( )
static

Turns the screen off.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.

◆ WriteConfigFileToDataLocal()

static void WriteConfigFileToDataLocal ( string  path,
string  content,
Action< bool >  callback 
)
static

Writes the configuration file to the /data/local/tmp/ path.

Parameters
pathThe path to the configuration file, e.g., /data/local/tmp/config.txt.
contentThe content of the configuration file.
callbackCallback:
  • true: written
  • false: failed to be written

◆ ResetAllKeyToDefault()

static void ResetAllKeyToDefault ( Action< bool >  callback)
static

Resets all keys to default configuration.

Parameters
callbackCallback:
  • true: reset
  • false: failed to reset

◆ SetAPPAsHome()

static void SetAPPAsHome ( SwitchEnum  switchEnum,
string  packageName 
)
static

Sets an app as the launcher app.

Parameters
switchEnumSwitch. Enumerations:
  • S_ON: set the app as the launcher app
  • S_OFF: cancel setting the app as the launcher app
packageNameThe app package name.

◆ KillAppsByPidOrPackageName()

static void KillAppsByPidOrPackageName ( int[]  pids,
string[]  packageNames 
)
static

Force quits app(s) by passing app PID or package name.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.
Parameters
pidsAn array of app PID(s).
packageNamesAn array of package name(s).

◆ KillBackgroundAppsWithWhiteList()

static void KillBackgroundAppsWithWhiteList ( string[]  packageNames)
static

Force quits background app(s) expect those in the allowlist.

Note
This is a protected API. You need to add <meta-data android:name="pico_advance_interface" android:value="0"/> to the app's AndroidManifest.xml file for calling this API, after which the app is unable to be published on the PICO Store.
Parameters
packageNamesAn array of package name(s) to be added to the allowlist. The corresponding app(s) in the allowlist will not be force quit.

◆ FreezeScreen()

static void FreezeScreen ( bool  freeze)
static

Freezes the screen to the front. The screen will turn around with the HMD. Note: This function only supports G2 4K series.

Parameters
freezeWhether to freeze the screen:
  • true: freeze
  • false: stop freezing

◆ IsMiracastOn()

static bool IsMiracastOn ( )
static

Gets the status of the screencast function.

Returns
The status of the screencast function:
  • true: screencast on
  • false: screencast off

◆ ConnectWifiDisplay()

static void ConnectWifiDisplay ( string  modelJson)
static

Casts the screen to the specified device.

Parameters
modelJsonA modelJson structure containing the following fields:
  • deviceAddress
  • deviceName
  • isAvailable (true-device available; false-device not available)

◆ ForgetWifiDisplay()

static void ForgetWifiDisplay ( string  address)
static

Forgets the device that have been connected for screencast.

Parameters
addressDevice address.

◆ RenameWifiDisplay()

static void RenameWifiDisplay ( string  address,
string  newName 
)
static

Renames the device connected for screencast (only the name for local storage).

Parameters
addressThe MAC address of the device.
newNameThe new device name.

◆ UpdateWifiDisplays()

static void UpdateWifiDisplays ( Action< string >  callback)
static

Manually updates the device list for screencast.

Parameters
callbackThe device list for screencast.

◆ GetConnectedWD()

static string GetConnectedWD ( )
static

Gets the information of the current connected device.

Returns
The information of the current connected device.

◆ SwitchLargeSpaceScene()

static void SwitchLargeSpaceScene ( bool  open,
Action< bool >  callback 
)
static

Switches the large space scene on.

Parameters
openWhether to switch the large space scene on:
  • true: switch on
  • false: not to switch on
callbackCallback:
  • true: success
  • false: failure

◆ GetSwitchLargeSpaceStatus()

static void GetSwitchLargeSpaceStatus ( Action< string >  callback)
static

Gets the status of the large space scene.

Parameters
callbackCallback:
  • true: status got
  • false: failed to get the status

◆ SaveLargeSpaceMaps()

static bool SaveLargeSpaceMaps ( )
static

Saves the large space map.

Returns
Whether the large space map has been saved:
  • true: saved
  • false: failed to save

◆ ExportMaps()

static void ExportMaps ( Action< bool >  callback)
static

Exports map(s).

Parameters
callbackCallback:
  • true: exported
  • false: failed to export

◆ ImportMaps()

static void ImportMaps ( Action< bool >  callback)
static

Imports map(s).

Parameters
callbackCallback:
  • true: imported
  • false: failed to import

◆ GetSensorStatus()

static int GetSensorStatus ( )
static

Gets the sensor's status.

Returns
The sensor's status:
  • 0: null
  • 1: 3DoF
  • 3: 6DoF

◆ SetSystemDisplayFrequency()

static void SetSystemDisplayFrequency ( float  rate)
static

Sets the system display frequency rate.

Parameters
rateThe frequency rate: 72; 90; 120. Other values are invalid.

◆ GetSystemDisplayFrequency()

static float GetSystemDisplayFrequency ( )
static

Gets the system display frequency rate.

Returns
The system display frequency rate.

◆ GetPredictedMainSensorStateNew()

static int GetPredictedMainSensorStateNew ( ref PxrSensorState2  sensorState,
ref int  sensorFrameIndex 
)
static

Gets the predicted status of the sensor.

Parameters
sensorStateSensor's coordinate:
  • pose: in-app coordinate
  • globalPose: global coordinate
sensorFrameIndexSensor frame index.
Returns
The predicted status of the sensor.

◆ GetCpuUsages()

static float[] GetCpuUsages ( )
static

Gets the CPU utilization of the current device.

Returns
The CPU utilization of the current device.

◆ GetDeviceTemperatures()

static float[] GetDeviceTemperatures ( int  type,
int  source 
)
static

Gets device temperature in Celsius.

Parameters
typeThe requested type of device temperature:
  • 0(DEVICE_TEMPERATURE_CPU): CPU temperature
  • 1(DEVICE_TEMPERATURE_GPU): GPU temperature
  • 2(DEVICE_TEMPERATURE_BATTERY): battery temperature
  • 3(DEVICE_TEMPERATURE_SKIN): surface temperature
sourceThe requested source of device temperature:
  • 0(TEMPERATURE_CURRENT): current temperature
  • 1(TEMPERATURE_THROTTLING): temperature threshold for throttling
  • 2(TEMPERATURE_SHUTDOWN): temperature threshold for shutdown
  • 3(TEMPERATURE_THROTTLING_BELOW_VR_MIN): temperature threshold for throttling. If the actual temperature is higher than the threshold, the lowest clock frequency for VR mode will not be met
Returns
An array of requested device temperatures in Celsius.

◆ ControlSetAutoConnectWIFIWithErrorCodeCallback()

static void ControlSetAutoConnectWIFIWithErrorCodeCallback ( String  ssid,
String  pwd,
int  ext,
Action< int >  callback 
)
static

Connects the device to a specified Wi-Fi.

Parameters
ssidWi-Fi name.
pwdWi-Fi password.
extReserved parameter, pass 0 by default.
callbackThe callback for indicating whether the Wi-Fi connection is successful:
  • 0: connected
  • 1: password error
  • 2: unknown error

◆ AppKeepAlive()

static void AppKeepAlive ( String  appPackageName,
bool  keepAlive,
int  ext 
)
static

Keeps an app active. In other words, improves the priority of an app, thereby making the system not to force quit the app.

Parameters
appPackageNameApp package name.
keepAliveWhether to keep the app active (i.e., whether to enhance the priority of the app):
  • true: keep
  • false: not keep
extReserved parameter, pass 0 by default.

◆ EnableFaceTracking()

static void EnableFaceTracking ( bool  enable)
static

Enables/disables face tracking.

Note
Supported by PICO 4 Pro/Enterprise.
Parameters
enableWhether to enable/disable face tracking:
  • true: enable
  • false: disable

◆ EnableLipSync()

static void EnableLipSync ( bool  enable)
static

Enables/disables lipsync.

Note
Supported by PICO 4 Pro/Enterprise.
Parameters
enableWhether to enable/disable lipsync:
  • true: enable
  • false: disable

◆ GetFaceTrackingData()

static void GetFaceTrackingData ( Int64  ts,
GetDataType  flags,
ref PxrFaceTrackingInfo  faceTrackingInfo 
)
static

Gets face tracking data.

Note
Supported by PICO 4 Pro/Enterprise.
Parameters
ts(Optional) A reserved parameter, pass 0.
flagsThe face tracking mode to retrieve data for. Enumertions:
  • PXR_GET_FACE_DATA_DEFAULT (invalid, only for making it compatible with older SDK version)
  • PXR_GET_FACE_DATA: face only
  • PXR_GET_LIP_DATA: lipsync only
  • PXR_GET_FACELIP_DATA: hybrid (both face and lipsync)
faceTrackingInfoReturns the PxrFaceTrackingInfo struct that contains the following face tracking data:
  • timestamp: Int64, reserved field
  • blendShapeWeight: float[], pass 0.
  • videoInputValid: float[], the input validity of the upper and lower parts of the face.
  • laughingProb: float[], the coefficient of laughter.
  • emotionProb: float[], the emotion factor.
  • reserved: float[], reserved field.

◆ TimingStartup()

static void TimingStartup ( int  year,
int  month,
int  day,
int  hour,
int  minute,
bool  open 
)
static

Schedules auto startup for the device. Note: Supported by PICO Neo3 series.

Parameters
yearYear, for example, 2022.
monthMonth, for example, 2.
dayDay, for example, 22.
hourHour, for example, 22.
minuteMinute, for example, 22.
openWhether to enable scheduled auto startup for the device:
  • true: enable
  • false: disable

◆ TimingShutdown()

static void TimingShutdown ( int  year,
int  month,
int  day,
int  hour,
int  minute,
bool  open 
)
static

Schedules auto shutdown for the device. Note: Supported by PICO Neo3 series.

Parameters
yearYear, for example, 2022.
monthMonth, for example, 2.
dayDay, for example, 22.
hourHour, for example, 22.
minuteMinute, for example, 22.
openWhether to enable scheduled auto shutdown for the device:
  • true: enable
  • false: disable

◆ StartVrSettingsItem()

static void StartVrSettingsItem ( StartVRSettingsEnum  settingsEnum,
bool  hideOtherItem,
int  ext 
)
static

Displays a specified settings screen. Note: Supported by PICO Neo3 and PICO 4 series.

Parameters
settingsEnumThe enumerations of settings screen:
  • START_VR_SETTINGS_ITEM_WIFI: the Wi-Fi settings screen;
  • START_VR_SETTINGS_ITEM_BLUETOOTH: the bluetooth settings screen;
  • START_VR_SETTINGS_ITEM_CONTROLLER: the controller settings screen;
  • START_VR_SETTINGS_ITEM_LAB: the lab settings screen;
  • START_VR_SETTINGS_ITEM_BRIGHTNESS: the brightness settings screen;
  • START_VR_SETTINGS_ITEM_GENERAL): the general settings screen;
  • START_VR_SETTINGS_ITEM_NOTIFICATION: the notification settings screen.
hideOtherItemWhether to display the selected settings screen:
  • true: display
  • false: hide
extReserved parameter, pass 0 by default.

◆ SwitchVolumeToHomeAndEnter()

static void SwitchVolumeToHomeAndEnter ( SwitchEnum  switchEnum,
int  ext 
)
static

Changes the Volume key's function to that of the Home and Enter key's, or restores the volume adjustment function to the Volume key.

Note
Supported by PICO 4 only.
Parameters
switchEnumWhether to change the Volume key's function:
  • S_ON: change
  • S_OFF: do not change
extReserved parameter, pass 0 by default.

◆ IsVolumeChangeToHomeAndEnter()

static SwitchEnum IsVolumeChangeToHomeAndEnter ( )
static

Gets whether the Volume key's function has been changed to that of the Home and Enter key's.

Note
Supported by PICO 4 only.
Returns
  • S_ON: changed
  • S_OFF: not changed

◆ InstallOTAPackage()

static int InstallOTAPackage ( String  otaPackagePath)
static

Upgrades the OTA.

Parameters
otaPackagePathThe location of the OTA package.
Returns
  • 0: success
  • 1: failure
  • 2: OTA package version too low

◆ GetAutoConnectWiFiConfig()

static string GetAutoConnectWiFiConfig ( )
static

Gets the configuration of the Wi-Fi nerwork that the device automatically connnects to.

Returns
The SSID and password of the Wi-Fi network.

◆ GetTimingStartupStatus()

static string GetTimingStartupStatus ( )
static

Gets the scheduled auto startup settings for the device.

Returns
  • open: the status of scheduled auto startup:
    • true: enabled
    • false: disabled
  • time: the time when the device auto starts up. Returned when open is true.

◆ GetTimingShutdownStatus()

static string GetTimingShutdownStatus ( )
static

Gets the scheduled auto shutdown settings for the device.

Returns
  • open: the status of scheduled auto shutdown:
    • true: enabled
    • false: disabled
  • time: the time when the device auto shuts down. Returned when open is true.

◆ GetControllerKeyState()

static int GetControllerKeyState ( ControllerKeyEnum  pxrControllerKey)
static

Gets the status of a specified controller key.

Parameters
pxrControllerKeyThe enumerations of controller key:
  • CONTROLLER_KEY_JOYSTICK
  • CONTROLLER_KEY_MENU
  • CONTROLLER_KEY_TRIGGER
  • CONTROLLER_KEY_RIGHT_A
  • CONTROLLER_KEY_RIGHT_B
  • CONTROLLER_KEY_LEFT_X
  • CONTROLLER_KEY_LEFT_Y
  • CONTROLLER_KEY_LEFT_GRIP
  • CONTROLLER_KEY_RIGHT_GRIP
Returns
The key's status:
  • 0: disabled
  • 1: enabled

◆ GetPowerOffWithUSBCable()

static SwitchEnum GetPowerOffWithUSBCable ( )
static

Gets the status of the switch for setting whether to power off the USB cable when the device is shut down.

Returns
The switch's status:
  • PBS_SwitchEnum#S_ON: on
  • PBS_SwitchEnum#S_OFF: off

◆ GetScreenOffDelay()

static ScreenOffDelayTimeEnum GetScreenOffDelay ( )
static

Gets the screen timeout setting for the device.

Returns
PBS_ScreenOffDelayTimeEnum: the enumerations of screen timeout.

◆ GetSleepDelay()

static SleepDelayTimeEnum GetSleepDelay ( )
static

Gets the sleep timeout settings for the device.

Returns
PBS_SleepDelayTimeEnum: the enumeration of sleep timeout.

◆ GetPowerKeyStatus()

static string GetPowerKeyStatus ( )
static

Gets the Power key's settings.

Returns
  • null: not set
  • singleTap: whether a single-tap event has been set
  • longTap: whether a long-press event has been set
  • longPressTime: the time after which the long-press event takes place. Returned when longTap is true.

◆ GetEnterKeyStatus()

static int GetEnterKeyStatus ( )
static

Get the Enter key's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetVolumeKeyStatus()

static int GetVolumeKeyStatus ( )
static

Get the Volume key's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetBackKeyStatus()

static int GetBackKeyStatus ( )
static

Get the Back key's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetHomKeyStatus()

static string GetHomKeyStatus ( HomeEventEnum  homeEvent)
static

Gets the event setting for the Home key.

Parameters
homeEventThe enumerations of event type:
  • SINGLE_CLICK: single-click event
  • DOUBLE_CLICK: double-click event
Returns
  • The function you set for single-click or double-click event will be returned.
  • If you have not set any function for the event type you pass in the request, the response will return null.
  • For function enumerations, see PropertySetHomeKey or PropertySetHomeKeyAll.

◆ GetSwitchSystemFunctionStatus()

static void GetSwitchSystemFunctionStatus ( SystemFunctionSwitchEnum  systemFunction,
Action< int >  callback 
)
static

Gets the status of a specified system function switch.

Parameters
systemFunctionThe enumerations of system function switch:
  • SFS_USB: USB debugging
  • SFS_AUTOSLEEP: auto sleep
  • SFS_SCREENON_CHARGING: screen-on charging
  • SFS_OTG_CHARGING: OTG charging
  • SFS_RETURN_MENU_IN_2DMODE: display the Return icon on the 2D screen
  • SFS_COMBINATION_KEY: combination key
  • SFS_CALIBRATION_WITH_POWER_ON: calibration with power on
  • SFS_SYSTEM_UPDATE: system update
  • SFS_CAST_SERVICE: phone casting service
  • SFS_EYE_PROTECTION: eye-protection mode
  • SFS_SECURITY_ZONE_PERMANENTLY: permanently disable the 6DoF play area
  • SFS_Auto_Calibration: auto recenter/recalibrate
  • SFS_USB_BOOT: USB plug-in boot
  • SFS_VOLUME_UI: global volume UI
  • SFS_CONTROLLER_UI: global controller connected UI
  • SFS_NAVGATION_SWITCH: navigation bar
  • SFS_SHORTCUT_SHOW_RECORD_UI: screen recording button UI
  • SFS_SHORTCUT_SHOW_FIT_UI: PICO fit UI
  • SFS_SHORTCUT_SHOW_CAST_UI: screencast button UI
  • SFS_SHORTCUT_SHOW_CAPTURE_UI: screenshot button UI
  • SFS_USB_FORCE_HOST: set the Neo3 device as the host device
  • SFS_SET_DEFAULT_SAFETY_ZONE: set a default play area for a Neo3 device
  • SFS_ALLOW_RESET_BOUNDARY: allow to reset customized boundary
  • SFS_BOUNDARY_CONFIRMATION_SCREEN: whether to display the boundary confirmation screen
  • SFS_LONG_PRESS_HOME_TO_RECENTER: long press the Home key to recenter
  • SFS_POWER_CTRL_WIFI_ENABLE: Neo3 device stays connected to the network when the device sleeps/turns off
  • SFS_WIFI_DISABLE: disable Wi-Fi for Neo3 device
  • SFS_SIX_DOF_SWITCH: 6DoF position tracking
  • SFS_INVERSE_DISPERSION: anti-dispersion
  • PBS_SystemFunctionSwitchEnum.SFS_LOGCAT: system log switch (/data/logs)
  • PBS_SystemFunctionSwitchEnum.SFS_PSENSOR: PSensor switch (need to restart the device to make the setting take effect)
  • PBS_SystemFunctionSwitchEnum.SFS_SYSTEM_UPDATE_OTA: OTA upgrade
  • PBS_SystemFunctionSwitchEnum.SFS_SYSTEM_UPDATE_APP: app upgrade and update
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_WLAN_UI: quickly set whether to show the WLAN button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_BOUNDARY_UI: quickly set whether to show the boundary button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_BLUETOOTH_UI: quickly set whether to show the bluetooth button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_CLEAN_TASK_UI: quickly set whether to show the one-click clear button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI: quickly set whether to show the IPD adjustment button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_POWER_UI: quickly set whether to show the power button
  • PBS_SystemFunctionSwitchEnum.SFS_SHORTCUT_SHOW_EDIT_UI: quickly set whether to show the edit button
  • PBS_SystemFunctionSwitchEnum.SFS_BASIC_SETTING_APP_LIBRARY_UI: the button for customizing the app library
  • PBS_SystemFunctionSwitchEnum.SFS_BASIC_SETTING_SHORTCUT_UI: the button for customizing quick settings
callbackThe callback that returns the switch's status:
  • 0: off
  • 1: on
  • 2: not supported by device For the PBS_SystemFunctionSwitchEnum.SFS_SYSTEM_UPDATE siwtch, the returns are as follows:
  • 0: off
  • 1: OTA upgrade on
  • 2: app upgrade on
  • 3: OTA and app upgrade on

◆ GetUsbConfigurationOption()

static string GetUsbConfigurationOption ( )
static

Gets the configured USB mode.

Returns
  • MTP: MTP mode
  • CHARGE: charging mode

◆ GetCurrentLauncher()

static string GetCurrentLauncher ( )
static

Gets the current launcher.

Returns
The package name or class name of the launcher.

◆ PICOCastInit()

static int PICOCastInit ( Action< int >  callback)
static

Initializes the screencast service.

Parameters
callbackThe callback:
  • 0: disconnect
  • 1: connect
  • 2: no mic permission
Returns
  • 0: failure
  • 1: success

◆ PICOCastSetShowAuthorization()

static int PICOCastSetShowAuthorization ( int  authZ)
static

Sets whether to show the screencast authorization window.

Parameters
authZ
  • 0: ask every time (default)
  • 1: always allow
  • 2: not accepted
Returns
  • 0: failure
  • 1: success

◆ PICOCastGetShowAuthorization()

static int PICOCastGetShowAuthorization ( )
static

Gets the setting of whether to show the screencast authorization window.

Returns
  • 0: ask every time (default)
  • 1: always allow
  • 2: not accepted

◆ PICOCastGetUrl()

static string PICOCastGetUrl ( PICOCastUrlTypeEnum  urlType)
static

Gets the URL for screencast.

Parameters
urlTypeThe enumerations of URL type:
  • NormalURL: Normal URL. The screencast authorization window will show if it is not set.
  • NoConfirmURL: Non-confirm URL. The screencast authorization window will not show in the browser. Screencast will start once you enter the URL.
  • RtmpURL: Returns the RTMP live streaming URL. The screencast authorization window will not appear on the VR headset's screen.
Returns
The URL for screencast.

◆ PICOCastStopCast()

static int PICOCastStopCast ( )
static

Stops screencast.

Returns
  • 0: failure
  • 1: success

◆ PICOCastSetOption()

static int PICOCastSetOption ( PICOCastOptionOrStatusEnum  castOptionOrStatus,
PICOCastOptionValueEnum  castOptionValue 
)
static

sets screencast-related properties.

Parameters
castOptionOrStatusThe enumerations of the property to set:
  • OPTION_RESOLUTION_LEVEL: resolution level
  • OPTION_BITRATE_LEVEL: bitrate level
  • OPTION_AUDIO_ENABLE: whether to enable the audio
castOptionValueThe values that can be set for each property:
  • For OPTION_RESOLUTION_LEVEL:
    • OPTION_VALUE_RESOLUTION_HIGH
    • OPTION_VALUE_RESOLUTION_MIDDLE
    • OPTION_VALUE_RESOLUTION_AUTO
    • OPTION_VALUE_RESOLUTION_HIGH_2K
    • OPTION_VALUE_RESOLUTION_HIGH_4K
  • For OPTION_BITRATE_LEVEL:
    • OPTION_VALUE_BITRATE_HIGH
    • OPTION_VALUE_BITRATE_MIDDLE
    • OPTION_VALUE_BITRATE_LOW
  • For OPTION_AUDIO_ENABLE:
    • OPTION_VALUE_AUDIO_ON
    • OPTION_VALUE_AUDIO_OFF
Returns
  • 0: failure
  • 1: success

◆ PICOCastGetOptionOrStatus()

static PICOCastOptionValueEnum PICOCastGetOptionOrStatus ( PICOCastOptionOrStatusEnum  castOptionOrStatus)
static

Gets the screencast-related property setting for the current device.

Parameters
castOptionOrStatusThe enumerations of the screencast property to get setting for:
  • OPTION_RESOLUTION_LEVEL: resolution level
  • OPTION_BITRATE_LEVEL: bitrate level
  • OPTION_AUDIO_ENABLE: whether the audio is enabled
  • PICOCAST_STATUS: returns the current screemcast status
Returns
The setting of the selected property:
  • For OPTION_RESOLUTION_LEVEL:
    • OPTION_VALUE_RESOLUTION_HIGH
    • OPTION_VALUE_RESOLUTION_MIDDLE
    • OPTION_VALUE_RESOLUTION_AUTO
    • OPTION_VALUE_RESOLUTION_HIGH_2K
    • OPTION_VALUE_RESOLUTION_HIGH_4K
  • For OPTION_BITRATE_LEVEL:
    • OPTION_VALUE_BITRATE_HIGH
    • OPTION_VALUE_BITRATE_MIDDLE
    • OPTION_VALUE_BITRATE_LOW
  • For OPTION_AUDIO_ENABLE:
    • OPTION_VALUE_AUDIO_ON
    • OPTION_VALUE_AUDIO_OFF
  • PICOCAST_STATUS :
    • STATUS_VALUE_STATE_STARTED
    • STATUS_VALUE_STATE_STOPPED
    • STATUS_VALUE_ERROR

◆ SetControllerPairTime()

static void SetControllerPairTime ( ControllerPairTimeEnum  timeEnum,
Action< int >  callback 
)
static

Sets the duration after which the controllers enter the pairing mode.

Parameters
timeEnumDuration enumerations:
  • SIX: 6 seconds
  • FIFTEEN: 15 seconds
  • SIXTY: 60 seconds
  • ONE_HUNDRED_AND_TWENTY: 120 seconds (2 minutes)
  • SIX_HUNDRED: 600 seconds (5 minutes)
  • NEVER: never enter the pairing mode
callbackReturns the result:
  • 0: failure
  • 1: success

◆ GetControllerPairTime()

static void GetControllerPairTime ( Action< int >  callback)
static

Gets the duration after which the controllers enter the pairing mode.

Parameters
callbackReturns a duration enumeration from the following:
  • SIX: 6 seconds
  • FIFTEEN: 15 seconds
  • SIXTY: 60 seconds
  • ONE_HUNDRED_AND_TWENTY: 120 seconds (2 minutes)
  • SIX_HUNDRED: 600 seconds (5 minutes)
  • NEVER: never enter the pairing mode

◆ SetSystemLanguage()

static int SetSystemLanguage ( String  language)
static

Sets the system language for the device. For a language that is spoken in different countries/regions, the system language is then co-set by the language code and the device's country/region code. For example, if the lanaguage code is set to en and the device's country/region code is US, the system language will be set to English (United States).

Note
Only supported by PICO 4.
Parameters
languageSupported language codes:
  • cs: Čeština (Czech)
  • da: Dansk (Danish)
  • de: Deutsch (German)
  • el: Ελληνικά (Greek)
  • en: English (United States) / English (United Kingdom)
  • es: Español (España) / Español (Estados Unidos)
  • fi: Suomi (Finnish)
  • fr: Français (French)
  • it: Italiano (Italian)
  • ja: 日本語 (Japanese)
  • ko: 한국어 (Korean)
  • ms: Melayu (Malay)
  • nb: Norsk bokmål (Norwegian)
  • nl: Nederlands (Dutch)
  • pl: Polski (Polish)
  • pt: Português (Portuguese(Brasil)) / Português (Portuguese(Portugal))
  • ro: Română (Romanian)
  • ru: Русский (Russian)
  • sv: Svenska (Swedish)
  • th: ไทย (Thai)
  • tr: Türkçe (Turkish)
  • zh: 中文 (简体) (Chinese (Simplified)) / 中文 (中国香港) (Chinese (Hong Kong SAR of China)) 中文 (繁體) / (Chinese (Traditional)). For devices in Mainland China / Taiwan, China / Hong Kong SAR of China / Macao SAR of China, the country/region code has been defined in factory settings.
Returns
  • 0: success
  • 1: failure
  • 22: invalid language

◆ GetSystemLanguage()

static String GetSystemLanguage ( )
static

Gets the device's system language.

Note
Only supported by PICO 4.
Returns
The system language set for the device. For details, refer to the parameter description for SetSystemLanguage.

◆ ConfigWifi()

static int ConfigWifi ( String  ssid,
String  pwd 
)
static

Sets a default Wi-Fi network for the device. Once set, the device will automatically connect to the Wi-Fi network if accessible.

Note
Only supported by PICO 4.
Parameters
ssidThe SSID (name) of the Wi-Fi network.
pwdThe password of the Wi-Fi network.
Returns
  • 0: success
  • 1: failure

◆ GetConfiguredWifi()

static String[] GetConfiguredWifi ( )
static

Gets the device's default Wi-Fi network.

Note
Only supported by PICO 4.
Returns
The SSID (name) of the Wi-Fi network.

◆ SetSystemCountryCode()

static int SetSystemCountryCode ( String  countryCode,
Action< int >  callback 
)
static

Sets a country/region for the device.

Note
Only supported by PICO 4 in non-Mainland China countries/regions.
Parameters
countryCodeThe country/region code co-determines the device's system lanaguge with the language code you set via SetSystemLanguage. Below are supported country/region codes:
  • AD: Andorra
  • AT: Austria
  • AU: Australia
  • BE: Belgium
  • BG: Bulgaria
  • CA: Canada
  • CH: Switzerland
  • CZ: Czech Republic
  • DE: Germany
  • DK: Denmark
  • EE: Estonia
  • ES: Spain
  • FI: Finland
  • FR: France
  • GB: the Great Britain
  • GR: Greece
  • HR: Croatia
  • HU: Hungary
  • IE: Ireland
  • IL: Israel
  • IS: Iceland
  • IT: Italy
  • JP: Japan
  • KR: Korea
  • LI: Liechtenstein
  • LT: Lithuania
  • LU: Luxembourg
  • LV: Latvia
  • MC: Monaco
  • MT: Malta
  • MY: Malaysia
  • NL: Netherlands
  • NO: Norway
  • NZ: New Zealand
  • PL: Poland
  • PT: Portugal
  • RO: Romania
  • SE: Sweden
  • SG: Singapore
  • SI: Slovenia
  • SK: Slovakia
  • SM: San Marino
  • TR: Turkey
  • US: the United States
  • VA: Vatican
callbackSet the callback to get the result:
  • 0: success
  • 1: failure

◆ GetSystemCountryCode()

static string GetSystemCountryCode ( )
static

Gets the device's country/region code.

Note
Only supported by PICO 4.
Returns
A string value that indicates the device's current country/region code. For supported country/region codes, see the parameter description in SetSystemCountryCode.

◆ SetSkipInitSettingPage()

static int SetSkipInitSettingPage ( int  flag)
static

Sets the page to skip in initialization settings.

Note
Only supported by PICO 4.
Parameters
flagSet the flag. The first 6 bits are valid, the 7th to 32rd bits are reserved. For each bit, 0 indicates showing and 1 indicates hiding.
  • Constants#INIT_SETTING_HANDLE_CONNECTION_TEACHING: the controller connection tutorial page
  • Constants#INIT_SETTING_TRIGGER_KEY_TEACHING: the Trigger button tutorial page
  • Constants#INIT_SETTING_SELECT_LANGUAGE: the language selection page
  • Constants#INIT_SETTING_SELECT_COUNTRY: the country/region selection page. Only available for devices in non-Mainland China countries/regions.
  • Constants#INIT_SETTING_WIFI_SETTING: the Wi-Fi settings page
  • Constants#INIT_SETTING_QUICK_SETTING: the quick settings page

Below is an example implementation:

int flag = Constants.INIT_SETTING_HANDLE_CONNECTION_TEACHING | Constants.INIT_SETTING_TRIGGER_KEY_TEACHING;
int result = serviceBinder.pbsSetSkipInitSettingPage(flag,0);
Returns
  • 0: success
  • 1: failure

◆ GetSkipInitSettingPage()

static int GetSkipInitSettingPage ( )
static

Gets the page to skip in initialization settings.

Note
Only supported by PICO 4.
Returns
Returns the flag set in SetSkipInitSettingPage.

◆ IsInitSettingComplete()

static int IsInitSettingComplete ( )
static

Gets whether the initialization settings have been complete.

Note
Only supported by PICO 4.
Returns
  • 0: not complete
  • 1: complete

◆ StartActivity()

static int StartActivity ( String  packageName,
String  className,
String  action,
String  extra,
String[]  categories,
int[]  flags 
)
static

Starts an activity in another app.

Parameters
packageName(Optional) The app's package name.
className(Optional) The app's class name.
action(Optional) The action to be performed.
extraThe basic types of standard fields that can be used as extra data. See here for details.
categoriesStandard categories that can be used to further clarify an Intent. Add a new category to the intent. See here for details.
flagsAdd additional flags to the intent. See here for details.

Below is an example implementation:

// Launches the video player to play a video.
serviceBinder.pbsStartActivity("", "", "picovr.intent.action.player", "{\"uri\":\"/sdcard/test.mp4\",\"videoType\":0,\"videoSource\":1}", new String[]{Intent.CATEGORY_DEFAULT}, new int[]{Intent.FLAG_ACTIVITY_NEW_TASK},0);
Returns
  • 0: success
  • 1: failure

◆ SetPerformanceLevels()

static int SetPerformanceLevels ( PxrPerfSettings  which,
PxrSettingsLevel  level 
)
static

Sets a GPU or CPU level for the device.

Parameters
whichChoose to set a GPU or CPU level:
  • CPU
  • GPU
levelSelect a level from the following:
  • POWER_SAVINGS: power-saving level
  • SUSTAINED_LOW: low level
  • SUSTAINED_HIGH: high level
  • BOOST: top-high level, be careful to use this level
Returns
  • 0: success
  • 1: failure

◆ GetPerformanceLevels()

static PxrSettingsLevel GetPerformanceLevels ( PxrPerfSettings  which)
static

Gets the device's GPU or CPU level.

Parameters
whichChoose to get GPU or CPU level:
  • CPU
  • GPU
Returns
Returns one of the following levels:
  • POWER_SAVINGS: power-saving level
  • SUSTAINED_LOW: low level
  • SUSTAINED_HIGH: high level
  • BOOST: top-high level, be careful to use this level

◆ SetEyeFOV()

static int SetEyeFOV ( EyeType  eye,
float  fovLeft,
float  fovRight,
float  fovUp,
float  fovDown 
)
static

Sets FOV in four directions (left, right, up, and down) for specified eye(s).

Parameters
eyeThe eye to set FOV for:
  • LeftEye
  • RightEye
  • BothEye
fovLeftThe horizontal FOV (in degrees) for the left part of the eye, for example, 47.5.
fovRightThe horizontal FOV (in degrees) for the right part of the eye..
fovUpThe vertical FOV (in degrees) for the upper part of the eye.
fovDownThe vertical FOV (in degrees) for the lower part of the eye.
Returns
  • 0: success
  • 1: failure

◆ CustomizeAppLibrary()

static int CustomizeAppLibrary ( String[]  packageNames,
SwitchEnum  switchEnum 
)
static

Shows/hides specified app(s) in the library.

Note
Only supported by PICO Neo3 and PICO 4 series.
Parameters
packageNamesPackage name(s). If there are multiple names, use commas (,) to separate them.
switchEnumSpecifies to show/hide the app(s), enums:
  • S_ON: show
  • S_OFF: hide
Returns
  • 0: success
  • 1: failure

◆ GetControllerConnectState()

static int GetControllerConnectState ( )
static

Gets the controller connectivity status.

Note
Only supported by PICO Neo3 and PICO 4 series.
Returns
  • 0: both controllers are disconnected
  • 1: the left controller is connected
  • 2: the right controller is connected
  • 3: both controllers are connected

◆ GetControllerBattery()

static int[] GetControllerBattery ( )
static

Gets the controller battery level.

Note
Only supported by PICO Neo3 and PICO 4 series.
Returns
Returns the following information:
  • array[0]: the left controller's battery level
  • array[1]: the right controller's battery level
  • an integer from 1 to 5, which indicates the battery level, the bigger the integer, the higher the battery level

◆ GetAppLibraryHideList()

static string GetAppLibraryHideList ( )
static

Gets the apps that are hidden in the library.

Note
Only supported by PICO Neo3 and PICO 4 series.
Returns
The packages names of hidden apps. Multiple names are separated by commas (,).