少于 1 分钟阅读 次阅读

概要:本文整理 RK3588 Android 平台多屏异显相关的调试命令,包含已验证的在指定屏幕启动应用、鼠标跨屏显示开关,以及待验证的显示接口状态查看、系统识别到的显示器查询、输入设备绑定排查、桌面模式与自由窗口开关等命令。

1 相关命令

1.1 已验证

  • 异显启动应用:在指定 Display 上打开应用
# 测试异显:Display 2 打开设置
am start --display 2 -a android.settings.SETTINGS

# 测试异显:Display 3 打开浏览器
am start --display 3 -a android.intent.action.VIEW -d https://www.baidu.com
  • 鼠标跨屏显示:异显状态下,开机鼠标默认在主屏显示;当鼠标移动到屏幕边缘时,会自动切换到副屏的中心位置显示
setprop sys.mouse.presentation 1

1.2 未验证

  1. 查看 DP / HDMI 是否接入
for f in /sys/class/drm/card0-*/status; do echo $f; cat $f; done
  1. 查看 Android 识别到几个显示器
cmd display get-displays
  1. 查看显示详细信息
dumpsys display | grep -iE "DisplayDeviceInfo|Display [0-9]|HDMI|DP|state|uniqueId|mode"
  1. 测试副屏输入
input -d 2 keyevent 4
input -d 3 keyevent 4
  1. 查看鼠标绑定在哪个 Display
dumpsys input | grep -iE "Cursor Input Mapper|FocusedDisplayId|DisplayId:"
  1. 查看输入系统详细信息
dumpsys input | grep -iE "Viewport|displayId|pointer|mouse|cursor|touch"
  1. 查看有没有多屏 / 鼠标相关开关
settings list global | grep -iE "display|desktop|freeform|mouse|pointer|external"
settings list system | grep -iE "display|desktop|freeform|mouse|pointer|external"
settings list secure | grep -iE "display|desktop|freeform|mouse|pointer|external"
  1. 尝试打开外接屏桌面模式
settings put global force_desktop_mode_on_external_displays 1
settings put global enable_freeform_support 1
reboot
  1. 重启后复测
cmd display get-displays
dumpsys input | grep -iE "Cursor Input Mapper|FocusedDisplayId|DisplayId:"

留下评论