Android 在使用adb通话时,如何打开拨号板?

Android 在使用adb通话时,如何打开拨号板?,android,shell,adb,Android,Shell,Adb,当我需要看医生时,我必须: 致电666 等5秒钟 按1 等5秒钟 按20301990 等5秒钟 按1 所以我想自动化所有这些步骤 我知道我可以通过以下方式拨打电话: adb shell am start -a android.intent.action.CALL -d tel:666666666 我可以通过以下方式模拟输入: sleep 5 adb shell input text "1" sleep 5 adb shell input text "20*30*1

当我需要看医生时,我必须:

  • 致电666
  • 等5秒钟
  • 按1
  • 等5秒钟
  • 按20301990
  • 等5秒钟
  • 按1
  • 所以我想自动化所有这些步骤

    我知道我可以通过以下方式拨打电话:

    adb shell am start -a android.intent.action.CALL -d tel:666666666
    
    我可以通过以下方式模拟输入:

    sleep 5
    adb shell input text "1"
    sleep 5
    adb shell input text "20*30*1990"
    sleep 5
    adb shell input text "1"
    
    但是如果我在
    adb shell am start-a android.intent.action.CALL-d tel:66666
    之后和
    adb shell输入文本“1”之前不打开拨号板,它将无法工作


    因此,我的问题是:在使用adb进行通话时,如何打开拨号板?

    您可以找到拨号板按钮的坐标,然后通过发送
    输入点击x y来模拟按下操作
    如果您的自动化将在不同类型的多个设备上使用,我建议您编写一个简单的python脚本,用于完成该任务