PICO Unity XR SDK
PXR_Enterprise Class Reference

Static Public Member Functions

static void InitEnterpriseService (string objectName)
 Initializes the enterprise service for a specified object. Must be called before calling other enterprise APIs. More...
 
static void BindEnterpriseService ()
 Binds the enterprise service. Must be called before calling other system related functions.
 
static void UnBindEnterpriseService ()
 Unbinds the enterprise service.
 
static bool StartBatteryReceiver (string objName)
 Turns on the power service for a specified object. More...
 
static bool StopBatteryReceiver ()
 Turns off the power 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 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 using this API. More...
 
static int GetCurrentVolumeNumber ()
 Gets the current volume. Call InitAudioDevice to initialize the audio device before using this API. More...
 
static bool VolumeUp ()
 Increases the volume. Call InitAudioDevice to initialize the audio device before using this API. More...
 
static bool VolumeDown ()
 Decreases the volume. Call InitAudioDevice to initialize the audio device before using this API. More...
 
static bool SetVolumeNum (int volume)
 Sets a volume. Call InitAudioDevice to initialize the audio device before using this API. More...
 
static string StateGetDeviceInfo (SystemInfoEnum type)
 Gets the specified type of device information. More...
 
static void ControlSetDeviceAction (DeviceControlEnum deviceControl, Action< int > callback)
 Shuts down or reboots the device. 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 button event. More...
 
static void PropertySetHomeKeyAll (HomeEventEnum eventEnum, HomeFunctionEnum function, int timesetup, string pkg, string className, Action< bool > callback)
 Sets extended settings for the Home button. More...
 
static void PropertyDisablePowerKey (bool isSingleTap, bool enable, Action< int > callback)
 Sets the Power button's 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 configuration mode. 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 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 button.
 
static void DisableEnterKey ()
 Disables the Confirm button.
 
static void EnableVolumeKey ()
 Enables the Volume button.
 
static void DisableVolumeKey ()
 Disables the Volume button.
 
static void EnableBackKey ()
 Enables the Back button.
 
static void DisableBackKey ()
 Disables the Back button.
 
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 buttons 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. 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 looking for devices that can be used for screen casting.
 
static void StopScan ()
 Stops looking 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. The name is only for local storage. More...
 
static void SetWDModelsCallback ()
 Sets the callback for the scanning result, which returns List<PBS_WifiDisplayModel> that contains the devices previously connected for screencast and the devices currently found for screencast.
 
static void SetWDJsonCallback ()
 Sets the callback for the scanning result, which returns the JSON string that contains the devices previously connected for screencast and the devices currently found for screencast.
 
static void UpdateWifiDisplays (Action< string > callback)
 Manually updates the list of devices for screencast. More...
 
static string GetConnectedWD ()
 Gets the information of the currently 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 maps. The exported maps are stored in the /maps/export file. More...
 
static void ImportMaps (Action< bool > callback)
 Imports maps. Need to copy maps to the /maps folder. More...
 
static float[] GetCpuUsages ()
 Gets each CPU's utilization for the current device. More...
 
static float[] GetDeviceTemperatures (int type, int source)
 Gets device temperature in Celsius. More...
 
static void Capture ()
 Captures the current screen. More...
 
static void Record ()
 Records the screen. Call this function again to stop recording. More...
 
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 TimingStartup (int year, int month, int day, int hour, int minute, bool open)
 Schedules auto startup for the device. More...
 
static void TimingShutdown (int year, int month, int day, int hour, int minute, bool open)
 Schedules auto shutdown for the device. More...
 
static void StartVrSettingsItem (StartVRSettingsEnum settingsEnum, bool hideOtherItem, int ext)
 Displays a specified settings screen. More...
 
static void SwitchVolumeToHomeAndEnter (SwitchEnum switchEnum, int ext)
 Changes the Volume button's function to that of the Home and Enter button's, or restores the volume adjustment function to the Volume button. More...
 
static SwitchEnum IsVolumeChangeToHomeAndEnter ()
 Gets whether the Volume button's function has been changed to that of the Home and Enter button's. More...
 
static int InstallOTAPackage (String otaPackagePath)
 Upgrades the OTA. More...
 
static string GetAutoConnectWiFiConfig ()
 Gets the configuration of the Wi-Fi network that the device automatically connects 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 button. More...
 
static int SetControllerKeyState (ControllerKeyEnum pxrControllerKey, SwitchEnum status)
 Enables or disables a specified controller button. More...
 
static SwitchEnum GetPowerOffWithUSBCable ()
 Gets the status of the switch which is for powering 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 current settings for the Power button. More...
 
static int GetEnterKeyStatus ()
 Get the Enter button's status. More...
 
static int GetVolumeKeyStatus ()
 Get the Volume button's status. More...
 
static int GetBackKeyStatus ()
 Get the Back button's status. More...
 
static string GetHomKeyStatus (HomeEventEnum homeEvent)
 Gets the event settings for the Home button. 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 options. More...
 
static PICOCastOptionValueEnum PICOCastGetOptionOrStatus (PICOCastOptionOrStatusEnum castOptionOrStatus)
 Gets the screencast settings for the current device. 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 language 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 CustomizeAppLibrary (String[] packageNames, SwitchEnum switchEnum)
 Shows/hides specified app(s) in the library. More...
 
static int[] GetControllerBattery ()
 Gets the controller's battery level. More...
 
static int GetControllerConnectState ()
 Gets the controller's connection status. More...
 
static string GetAppLibraryHideList ()
 Gets the apps that are hidden in the library. More...
 
static int SetScreenCastAudioOutput (ScreencastAudioOutputEnum screencastAudioOutput)
 Sets the device that outputs audio during screen casting. More...
 
static ScreencastAudioOutputEnum GetScreenCastAudioOutput ()
 Gets the device that outputs audio during screen casting. More...
 
static int UPxr_CustomizeSettingsTabStatus (CustomizeSettingsTabEnum customizeSettingsTabEnum, SwitchEnum switchEnum)
 Displays or hides the specified tab or option on the Settings pane. More...
 
static SwitchEnum UPxr_GetCustomizeSettingsTabStatus (CustomizeSettingsTabEnum customizeSettingsTabEnum)
 Gets the status set for the specified tab or option on the Settings pane. More...
 

Detailed Description

Enterprise APIs are only supported by enterprise devices, including PICO Neo2, Neo2 Eye, Neo3 Pro, Neo3 Pro Eye, G2 4K/4K E/4K Plus (system version 4.0.3 or later), and PICO 4 Enterprise. Do not use them on consumer devices.

Member Function Documentation

◆ InitEnterpriseService()

static void InitEnterpriseService ( string  objectName)
static

Initializes the enterprise service for a specified object. Must be called before calling other enterprise APIs.

Parameters
objectNameThe name of the object to initialize the enterprise service for.

◆ StartBatteryReceiver()

static bool StartBatteryReceiver ( string  objName)
static

Turns on the power service for a specified object.

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

◆ StopBatteryReceiver()

static bool StopBatteryReceiver ( )
static

Turns off the power 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. Value range: [0,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. Value range: [0,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, you can then set param level.
levelBrightness level. Value range: [1,255].

◆ 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 object.

Parameters
objNameThe name of the 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 using this API.

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 using this API.

Returns
An int value that indicates the current volume. Value range: [0,15].

◆ VolumeUp()

static bool VolumeUp ( )
static

Increases the volume. Call InitAudioDevice to initialize the audio device before using this API.

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 using this API.

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

◆ SetVolumeNum()

static bool SetVolumeNum ( int  volume)
static

Sets a volume. Call InitAudioDevice to initialize the audio device before using this API.

Parameters
volumeThe target volume. Value range: [0,15].
Returns
Whether the target volume has been set:
  • true: success
  • false: failure

◆ StateGetDeviceInfo()

static string StateGetDeviceInfo ( SystemInfoEnum  type)
static

Gets the specified type of device information.

Parameters
typeThe target information type. Enumerations:
  • ELECTRIC_QUANTITY: battery
  • PUI_VERSION: system 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

Shuts down or reboots the device.

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 to perform this operation

◆ 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 to perform 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 button 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 the screen
  • VALUE_HOME_DISABLE: disable the Home button
  • VALUE_HOME_GO_TO_HOME: open the launcher
callbackCallback:
  • true: success
  • false: failure

◆ PropertySetHomeKeyAll()

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

Sets extended settings for the Home button.

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 the screen
  • VALUE_HOME_DISABLE: disable the Home button
  • 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 button, 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 button's event.

Parameters
isSingleTapWhether it is a single click event:
  • true: single-click event
  • false: long-press event
enableEnable or disable the Power button:
  • true: enable
  • false: disable
callbackCallback:
  • 0: set
  • 1: failed to set

◆ 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 (only supported by PICO G2 4K)
  • TEN: 10s (only supported by PICO G2 4K)
  • 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 longer 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 (only supported by PICO G2 4K)
  • THIRTY: 30s (only supported by PICO G2 4K)
  • SIXTY: 60s (only supported by PICO G2 4K)
  • 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 (only supported by G2 and Neo2 devices)
  • SFS_RETURN_MENU_IN_2DMODE: display the Return icon on the 2D screen (only supported by G2 devices)
  • SFS_COMBINATION_KEY: combination key
  • SFS_CALIBRATION_WITH_POWER_ON: calibration with power on (only supported by G2 devices)
  • SFS_SYSTEM_UPDATE: system update
  • SFS_CAST_SERVICE: phone casting service (only supported by G2 and Neo3 Pro/Pro Eye devices)
  • SFS_EYE_PROTECTION: eye-protection mode
  • SFS_SECURITY_ZONE_PERMANENTLY: permanently disable the 6DoF play area (not supported by G2 devices)
  • SFS_GLOBAL_CALIBRATION: global calibration (only supported by G2 devices)
  • SFS_Auto_Calibration: auto calibration (only supported by G2 devices)
  • SFS_USB_BOOT: USB plug-in boot
  • SFS_VOLUME_UI: global volume UI (need to restart the device to make the setting take effect)
  • 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 (only supported by Neo devices for Chinese Mainland)
  • SFS_SHORTCUT_SHOW_CAST_UI: screencast button UI
  • SFS_SHORTCUT_SHOW_CAPTURE_UI: screenshot button UI
  • SFS_USB_FORCE_HOST: set the Neo3 Pro/Pro Eye device as the host device (not supported by G2 and Neo2 devices)
  • SFS_SET_DEFAULT_SAFETY_ZONE: set a default play area for a Neo3 Pro/Pro Eye device (not supported by G2 devices)
  • SFS_ALLOW_RESET_BOUNDARY: allow to reset customized boundary. Neo3 Pro/Pro Eye devices can re-customize the boundary (not supported by G2 devices)
  • SFS_BOUNDARY_CONFIRMATION_SCREEN: whether to display the boundary confirmation screen (not supported by G2 devices)
  • SFS_LONG_PRESS_HOME_TO_RECENTER: long press the Home button to recenter (not supported by G2 devices)
  • SFS_POWER_CTRL_WIFI_ENABLE: Neo3 Pro/Pro Eye device stays connected to the network when the device sleeps/turns off (not supported by G2 and Neo2 devices)
  • SFS_WIFI_DISABLE: disable Wi-Fi (not supported by G2 and Neo2 devices)
  • SFS_SIX_DOF_SWITCH: 6DoF position tracking (not supported by G2 and Neo2 devices)
  • SFS_INVERSE_DISPERSION: anti-dispersion (need to restart the device to make the setting take effect; not supported by G2 and Neo2 devices)
  • SFS_LOGCAT: system log switch (/data/logs) (not supported by G2 and Neo2 devices)
  • SFS_PSENSOR: PSensor switch (need to restart the device to make the setting take effect; not supported by G2 and Neo2 devices)
  • SFS_SYSTEM_UPDATE_OTA: OTA upgrade (not supported by G2 and Neo2 devices)
  • SFS_SYSTEM_UPDATE_APP: app upgrade and update (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_WLAN_UI: quickly set whether to show the WLAN button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_BOUNDARY_UI: quickly set whether to show the boundary button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_BLUETOOTH_UI: quickly set whether to show the bluetooth button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_CLEAN_TASK_UI: quickly set whether to show the one-click clear button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI: quickly set whether to show the IPD adjustment button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_POWER_UI: quickly set whether to show the power button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_EDIT_UI: quickly set whether to show the edit button (not supported by G2 and Neo2 devices)
  • SFS_BASIC_SETTING_APP_LIBRARY_UI: the button for customizing the app library (not supported by G2 and Neo2 devices; only supported by system apps)
  • SFS_BASIC_SETTING_SHORTCUT_UI: the button for customizing quick settings (not supported by G2 and Neo2 devices; only supported by system apps)
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 configuration mode.

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

◆ SetControllerPairTime()

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

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

Note
Not supported by G2 4K devices.
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.

Note
Not supported by G2 4K devices.
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

◆ 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.
callbackWhether the configuration file has been successfully written:
  • true: written
  • false: failed to be written

◆ ResetAllKeyToDefault()

static void ResetAllKeyToDefault ( Action< bool >  callback)
static

Resets all buttons to default configuration.

Parameters
callbackWhether all keys have been successfully reset to default configuration:
  • 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
Only supported by G2 4K and Neo2 devices.
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: on
  • false: 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. The name is only 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 list of devices for screencast.

Parameters
callbackThe list of devices for screencast.

◆ GetConnectedWD()

static string GetConnectedWD ( )
static

Gets the information of the currently connected device.

Returns
The information of the currently connected device.

◆ SwitchLargeSpaceScene()

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

Switches the large space scene on.

Note
Not supported by G2 4K devices.
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.

Note
Not supported by G2 4K devices.
Parameters
callbackReturns the status of large space:
  • 0: switched off
  • 1: switched on

◆ SaveLargeSpaceMaps()

static bool SaveLargeSpaceMaps ( )
static

Saves the large space map.

Note
Not supported by G2 4K devices.
Returns
Whether the large space map has been saved:
  • true: saved
  • false: failed to save

◆ ExportMaps()

static void ExportMaps ( Action< bool >  callback)
static

Exports maps. The exported maps are stored in the /maps/export file.

Note
Not supported by G2 4K devices.
Parameters
callbackReturns the result:
  • true: exported
  • false: failed to export

◆ ImportMaps()

static void ImportMaps ( Action< bool >  callback)
static

Imports maps. Need to copy maps to the /maps folder.

Note
Not supported by G2 4K devices.
Parameters
callbackReturns the result:
  • true: imported
  • false: failed to import

◆ GetCpuUsages()

static float[] GetCpuUsages ( )
static

Gets each CPU's utilization for the current device.

Returns
An array of CPU utilization info.

◆ GetDeviceTemperatures()

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

Gets device temperature in Celsius.

Parameters
typeThe requested type of device temperature:
  • DEVICE_TEMPERATURE_CPU: CPU temperature
  • DEVICE_TEMPERATURE_GPU: GPU temperature
  • DEVICE_TEMPERATURE_BATTERY: battery temperature
  • DEVICE_TEMPERATURE_SKIN: surface temperature
sourceThe requested source of device temperature:
  • TEMPERATURE_CURRENT: current temperature
  • TEMPERATURE_THROTTLING: temperature threshold for throttling
  • TEMPERATURE_SHUTDOWN: temperature threshold for shutdown
  • 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 float device temperatures in Celsius.

◆ Capture()

static void Capture ( )
static

Captures the current screen.

Note
Not supported by G2 4K devices.

◆ Record()

static void Record ( )
static

Records the screen. Call this function again to stop recording.

Note
Not supported by G2 4K devices.

◆ 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.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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.

◆ TimingStartup()

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

Schedules auto startup for the device.

Note
Not supported by G2 4K devices.
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
Not supported by G2 4K devices.
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
Not supported by G2 4K devices.
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.

◆ SwitchVolumeToHomeAndEnter()

static void SwitchVolumeToHomeAndEnter ( SwitchEnum  switchEnum,
int  ext 
)
static

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

Note
Only supported by PICO 4 Enterprise.
Parameters
switchEnumWhether to change the Volume button's function:
  • S_ON: change
  • S_OFF: do not change
extReserved parameter, pass 0.

◆ IsVolumeChangeToHomeAndEnter()

static SwitchEnum IsVolumeChangeToHomeAndEnter ( )
static

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

Note
Only supported by PICO 4 Enterprise.
Returns
  • S_ON: changed
  • S_OFF: not changed

◆ InstallOTAPackage()

static int InstallOTAPackage ( String  otaPackagePath)
static

Upgrades the OTA.

Note
Not supported by G2 4K devices.
Parameters
otaPackagePathThe location of the OTA package.
Returns
  • 0: success
  • 1: failure
  • 21: OTA package version too low

◆ GetAutoConnectWiFiConfig()

static string GetAutoConnectWiFiConfig ( )
static

Gets the configuration of the Wi-Fi network that the device automatically connects 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.

Note
Not supported by G2 4K devices.
Returns
  • open: the status of scheduled auto startup:
    • true: enabled
    • false: disabled
  • time: the time when the device auto starts up, for example, 1658980380000. Returned when open is true.

◆ GetTimingShutdownStatus()

static string GetTimingShutdownStatus ( )
static

Gets the scheduled auto shutdown settings for the device.

Note
Not supported by G2 4K devices.
Returns
  • open: the status of scheduled auto shutdown:
    • true: enabled
    • false: disabled
  • time: the time when the device auto shuts down, for example, 1658980380000. Returned when open is true.

◆ GetControllerKeyState()

static int GetControllerKeyState ( ControllerKeyEnum  pxrControllerKey)
static

Gets the status of a specified controller button.

Note
Not supported by G2 4K devices.
Parameters
pxrControllerKeyThe enumerations of controller button:
  • 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 button's status:
  • 0: disabled
  • 1: enabled

◆ SetControllerKeyState()

static int SetControllerKeyState ( ControllerKeyEnum  pxrControllerKey,
SwitchEnum  status 
)
static

Enables or disables a specified controller button.

Note
Not supported by G2 4K devices.
Parameters
pxrControllerKeyThe enumerations of controller button:
  • 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
statusWhether to enable or disable the button:
  • S_ON: enable
  • S_OFF: disable
Returns
0 indicates success, other values indicate failure.

◆ GetPowerOffWithUSBCable()

static SwitchEnum GetPowerOffWithUSBCable ( )
static

Gets the status of the switch which is for powering off the USB cable when the device is shut down.

Returns
The switch's status:
  • S_ON: on
  • 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 current settings for the Power button.

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 button's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetVolumeKeyStatus()

static int GetVolumeKeyStatus ( )
static

Get the Volume button's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetBackKeyStatus()

static int GetBackKeyStatus ( )
static

Get the Back button's status.

Returns
  • 0: disabled
  • 1: enabled

◆ GetHomKeyStatus()

static string GetHomKeyStatus ( HomeEventEnum  homeEvent)
static

Gets the event settings for the Home button.

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 (only supported by G2 and Neo2 devices)
  • SFS_RETURN_MENU_IN_2DMODE: display the Return icon on the 2D screen (only supported by G2 devices)
  • SFS_COMBINATION_KEY: combination key
  • SFS_CALIBRATION_WITH_POWER_ON: calibration with power on (only supported by G2 devices)
  • SFS_SYSTEM_UPDATE: system update
  • SFS_CAST_SERVICE: phone casting service (only supported by G2 and Neo3 Pro/Pro Eye devices)
  • SFS_EYE_PROTECTION: eye-protection mode
  • SFS_SECURITY_ZONE_PERMANENTLY: permanently disable the 6DoF play area (not supported by G2 devices)
  • SFS_GLOBAL_CALIBRATION: global calibration (only supported by G2 devices)
  • SFS_Auto_Calibration: auto calibration (only supported by G2 devices)
  • SFS_USB_BOOT: USB plug-in boot
  • SFS_VOLUME_UI: global volume UI (need to restart the device to make the setting take effect)
  • 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 (only supported by Neo devices for Chinese Mainland)
  • SFS_SHORTCUT_SHOW_CAST_UI: screencast button UI
  • SFS_SHORTCUT_SHOW_CAPTURE_UI: screenshot button UI
  • SFS_USB_FORCE_HOST: set the Neo3 Pro/Pro Eye device as the host device (not supported by G2 and Neo2 devices)
  • SFS_SET_DEFAULT_SAFETY_ZONE: set a default play area for a Neo3 Pro/Pro Eye device (not supported by G2 devices)
  • SFS_ALLOW_RESET_BOUNDARY: allow to reset customized boundary. Neo3 Pro/Pro Eye devices supports recustomizing the boundary (not supported by G2 devices)
  • SFS_BOUNDARY_CONFIRMATION_SCREEN: whether to display the boundary confirmation screen (not supported by G2 devices)
  • SFS_LONG_PRESS_HOME_TO_RECENTER: long press the Home button to recenter (not supported by G2 devices)
  • SFS_POWER_CTRL_WIFI_ENABLE: Neo3 Pro/Pro Eye device stays connected to the network when the device sleeps/turns off (not supported by G2 and Neo2 devices)
  • SFS_WIFI_DISABLE: disable Wi-Fi (not supported by G2 and Neo2 devices)
  • SFS_SIX_DOF_SWITCH: 6DoF position tracking (not supported by G2 and Neo2 devices)
  • SFS_INVERSE_DISPERSION: anti-dispersion (need to restart the device to make the setting take effect; not supported by G2 and Neo2 devices)
  • SFS_LOGCAT: system log switch (/data/logs) (not supported by G2 and Neo2 devices)
  • SFS_PSENSOR: PSensor switch (need to restart the device to make the setting take effect; not supported by G2 and Neo2 devices)
  • SFS_SYSTEM_UPDATE_OTA: OTA upgrade (not supported by G2 and Neo2 devices)
  • SFS_SYSTEM_UPDATE_APP: app upgrade and update (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_WLAN_UI: quickly set whether to show the WLAN button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_BOUNDARY_UI: quickly set whether to show the boundary button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_BLUETOOTH_UI: quickly set whether to show the bluetooth button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_CLEAN_TASK_UI: quickly set whether to show the one-click clear button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_IPD_ADJUSTMENT_UI: quickly set whether to show the IPD adjustment button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_POWER_UI: quickly set whether to show the power button (not supported by G2 and Neo2 devices)
  • SFS_SHORTCUT_SHOW_EDIT_UI: quickly set whether to show the edit button (not supported by G2 and Neo2 devices)
  • SFS_BASIC_SETTING_APP_LIBRARY_UI: the button for customizing the app library (not supported by G2 and Neo2 devices; only supported by system apps)
  • SFS_BASIC_SETTING_SHORTCUT_UI: the button for customizing quick settings (not supported by G2 and Neo2 devices; only supported by system apps)
callbackThe callback that returns the switch's status:
  • 0: off
  • 1: on
  • 2: not supported by device For SFS_SYSTEM_UPDATE, 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.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Parameters
callbackThe callback:
  • 0: disconnect
  • 1: connect
  • 2: no microphone permission
Returns
  • 0: failure
  • 1: success Returns 0 when there is no microphone permission.

◆ PICOCastSetShowAuthorization()

static int PICOCastSetShowAuthorization ( int  authZ)
static

Sets whether to show the screencast authorization window.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Returns
  • 0: ask every time (default)
  • 1: always allow
  • 2: not accepted

◆ PICOCastGetUrl()

static string PICOCastGetUrl ( PICOCastUrlTypeEnum  urlType)
static

Gets the URL for screencast.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Returns
  • 0: failure
  • 1: success

◆ PICOCastSetOption()

static int PICOCastSetOption ( PICOCastOptionOrStatusEnum  castOptionOrStatus,
PICOCastOptionValueEnum  castOptionValue 
)
static

sets screencast options.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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 settings for the current device.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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 screencast 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

◆ 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 language 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
Not supported by G2 4K devices.
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
Not supported by G2 4K devices.
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
Not supported by G2 4K devices.
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
Not supported by G2 4K devices.
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
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later. This API works only before initialization is completed.
Parameters
countryCodeThe country/region code co-determines the device's system language 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
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later. This API works only before initialization is completed.
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
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later. This API works only before initialization is completed.
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
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later. This API works only before initialization is completed.
Returns
Returns the flag set in SetSkipInitSettingPage.

◆ IsInitSettingComplete()

static int IsInitSettingComplete ( )
static

Gets whether the initialization settings have been complete.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later. This API works only before initialization is completed.
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.

Note
Not supported by G2 4K devices.
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

◆ CustomizeAppLibrary()

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

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

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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

◆ GetControllerBattery()

static int[] GetControllerBattery ( )
static

Gets the controller's battery level.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
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

◆ GetControllerConnectState()

static int GetControllerConnectState ( )
static

Gets the controller's connection status.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Returns
  • 0: both controllers are disconnected
  • 1: the left controller is connected
  • 2: the right controller is connected
  • 3: both controllers are connected

◆ GetAppLibraryHideList()

static string GetAppLibraryHideList ( )
static

Gets the apps that are hidden in the library.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Returns
The packages names of hidden apps. Multiple names are separated by commas (,).

◆ SetScreenCastAudioOutput()

static int SetScreenCastAudioOutput ( ScreencastAudioOutputEnum  screencastAudioOutput)
static

Sets the device that outputs audio during screen casting.

Note
Only supported by PICO Neo3 Pro/Pro Eye and PICO 4 Enterprise devices.
Parameters
screencastAudioOutputSpecifies the device that outputs audio. Enumerations: AUDIO_SINK: the HMD AUDIO_TARGET: the receiver AUDIO_SINK_TARGET: both the HMD and the receiver
Returns
  • 0: success
  • 1: failure

◆ GetScreenCastAudioOutput()

static ScreencastAudioOutputEnum GetScreenCastAudioOutput ( )
static

Gets the device that outputs audio during screen casting.

Note
Only supported by PICO Neo3 Pro/Pro Eye and PICO 4 Enterprise devices.
Returns
Enumerations: AUDIO_SINK: the HMD AUDIO_TARGET: the receiver AUDIO_SINK_TARGET: both the HMD and the receiver

◆ UPxr_CustomizeSettingsTabStatus()

static int UPxr_CustomizeSettingsTabStatus ( CustomizeSettingsTabEnum  customizeSettingsTabEnum,
SwitchEnum  switchEnum 
)
static

Displays or hides the specified tab or option on the Settings pane.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Parameters
customizeSettingsTabEnumSpecifies the tab or option to display or hide. Enumerations:
  • CUSTOMIZE_SETTINGS_TAB_WLAN: the "WLAN" tab
  • CUSTOMIZE_SETTINGS_TAB_CONTROLLER: the "Controller" tab
  • CUSTOMIZE_SETTINGS_TAB_BLUETOOTH: the "Bluetooth" tab
  • CUSTOMIZE_SETTINGS_TAB_DISPLAY: the "Display" tab
  • CUSTOMIZE_SETTINGS_TAB_LAB: the "LAB" tab
  • CUSTOMIZE_SETTINGS_TAB_GENERAL_FACTORY_RESET: the "Factory Reset" option on the "General" tab
  • CUSTOMIZE_SETTINGS_TAB_GENERAL_LOCKSCREEN: the "Lock Screen" option on the "General" tab
switchEnumSets to display or hide the specified tab or option: S_ON: display S_OFF: hide
Returns
  • 0: success
  • 1: failure

◆ UPxr_GetCustomizeSettingsTabStatus()

static SwitchEnum UPxr_GetCustomizeSettingsTabStatus ( CustomizeSettingsTabEnum  customizeSettingsTabEnum)
static

Gets the status set for the specified tab or option on the Settings pane.

Note
Not supported by G2 4K devices. For Neo3 Pro/Pro Eye devices, the device's system version should be 5.0.0 or later.
Parameters
customizeSettingsTabEnumSpecifies the tab or option to get status for. Enumerations:
  • CUSTOMIZE_SETTINGS_TAB_WLAN: the "WLAN" tab
  • CUSTOMIZE_SETTINGS_TAB_CONTROLLER: the "Controller" tab
  • CUSTOMIZE_SETTINGS_TAB_BLUETOOTH: the "Bluetooth" tab
  • CUSTOMIZE_SETTINGS_TAB_DISPLAY: the "Display" tab
  • CUSTOMIZE_SETTINGS_TAB_LAB: the "LAB" tab
  • CUSTOMIZE_SETTINGS_TAB_GENERAL_FACTORY_RESET: the "Factory Reset" option on the "General" tab
  • CUSTOMIZE_SETTINGS_TAB_GENERAL_LOCKSCREEN: the "Lock Screen" option on the "General" tab
Returns
The status of the specified tab or option: S_ON: displayed S_OFF: hidden