Wake up Android with use adb or Eclipse (just before debug)?

后端 未结 9 698
温柔的废话
温柔的废话 2021-01-31 04:45

How to wake up Android with use adb - I want to wake up (if asleep) Android terminal before debugging every new version of application.

Typical flow is: 1. I do some cha

9条回答
  •  情深已故
    2021-01-31 05:04

    adb shell input keyevent KEYCODE_WAKEUP
    

    As described here, this wakes up the device. Behaves somewhat like KEYCODE_POWER but it has no effect if the device is already awake.

    To toggle sleep/wake with one command you can issue

    adb shell input keyevent KEYCODE_POWER
    

提交回复
热议问题