2 ADB Frequently Used Command¶
1. Modify screen density¶
adb shell wm density 560
Note: only applicable for Android 2D app, not for VR app
2. Get VR headset software version¶
adb shell "getprop | grep ro.pvr.internal.version"
3. Screen recording¶
adb shell screenrecord --time-limit 10 /sdcard/demo.mp4
Note: without “–time-limit 10”, default duration of the video will be 180 seconds
4. Send broadcast with action¶
adb shell am broadcast -a com.picovr.wing.player.playorpause
5. Show package name of installed application on device¶
adb shell pm list packages
6. Launch application with package name¶
adb shell am start -p com.xxx.xxx
7. Get apk path with package name¶
adb shell pm path com.xxx.xxx
8. Launch Firefox browser with specified link¶
adb shell am start -a android.intent.action.VIEW -d "https://ggnome.com/samples/pano2vr_5/tower/" org.mozilla.vrbrowser/org.mozilla.vrbrowser.VRBrowserActivity
9. Get IP address¶
adb shell ifconfig
10. Get MAC address¶
adb shell cat /sys/class/net/wlan0/address
11. Modify system attribute¶
Format of adb command to modify system attribute: adb shell setprop [Attribute] [Parameter]
Example: adb shell setprop persist.psensor.screenoff.delay 30
11.1. System sleep timeout¶
Attribute: persist.psensor.sleep.delay
Parameter: positive integer
Note: the unit is in seconds. to keep the system never sleep, parameter should set to -1.
11.2. Screen shutdown timeout¶
Attribute: persist.psensor.screenoff.delay
Parameter: positive integer
Note: the unit is in seconds. to keep the screen never shutdown, parameter should set to 65535, and make sure to set the system never sleep first.
11.3. Long press home button to reset orientation¶
Attribute: persist.pxr.3dof.freedom.calibration
Parameter: 0: to reset orientation only horizontally; 1: to reset orientation horizontally and vertically
11.4. 2D window default scaling¶
Attribute: persist.pvr.2dtovr.screen_scale
Parameter: 1: one times scaling; 2: two times scaling; 3: three times scaling
Note: need to reboot device.
11.5. Set controller calibration on device boot-up¶
Attribute: persist.pvr.openrecenter
Parameter: 0: to turn on power on calibration; 1: to turn off power on calibration
11.6. Single-eyed mode screen cast¶
Attribute: persist.pvr.wfd.enable
Parameter: 0: to turn off single-eyed mode; 1: to turn on single-eyed mode
11.7. Turn on system logcat¶
Attribute: persist.pvr.logcatch
Parameter: 0: to turn off system logcat; 1: to turn on system logcat
Note: need to reboot device.
11.8. Storage logcatch into internal storage¶
Attribute: persist.pvr.isLog2SDCard
Parameter: 0: to turn off; 1: to turn on
Note: need to reboot device.
11.9. Modify display mode¶
Attribute: pvr.display.type
Parameter: G2 3K: jdi3k75fps jdi3k90fps ;G2 4K: jdi2kt4k75 jdi4k75
11.10. Set FPS limit¶
Attribute: persist.pvr.config.target_fps
Parameter: positive integer
Note: to release limit, parameter should set to -1.
11.11. Set eyebuffer width¶
Attribute: persist.pvr.config.eyebuffer_width
Parameter: 1600; 2048; 2496(width and height recommend to be 1:1)
11.12. Set eyebuffer heigth¶
Attribute: persist.pvr.config.eyebuffer_height
Parameter: 1600; 2048; 2496(width and height recommend to be 1:1)
11.13. Whether to reset the pose data when the HMD wakes up¶
Attribute: persist.pvr.psensor.reset_pose
Parameter: 0: to turn off; 1: to turn on
11.14. Whether to show the confirm panel when the device is connected¶
Attribute: persist.pvr.show.adb_confirm
Parameter: 0: to hide; 1: to show
11.16. Settings of The Return Button of 2d Mode¶
Attribute: persist.pvr.2dtovr.button_back
Parameter: 0: to hide; 1: to show;
11.17. USB Plug-in Boot Mode¶
Attribute: persist.pvr.prebootmode
Parameter: 0: to charge; 1: to boot;
11.18. Combination keys¶
Attribute: persist.pvr.mulkey.enable
Parameter: 0: to turn off; 1: to turn on;
11.19. Accepting Upgrade from System¶
Attribute: persist.accept.systemupdates
Parameter: 0: not to accept; 1: to accept;
11.20. Charging while using¶
Attribute: persist.pvr.charge.policy
Parameter: 3 means on, 1 means off
11.21. Do you want to display the app permission prompt window¶
Attribute: persist.pvrpermission.autogrant
Parameter: 0 means on, 1 means off