Android ADB commands to get the device properties

后端 未结 4 1686
独厮守ぢ
独厮守ぢ 2020-12-02 04:53

I am trying to get the device properties from ADB commands. I can how ever get those values by running sample android application. How ever I wish to get using adb shell com

4条回答
  •  生来不讨喜
    2020-12-02 05:40

    You should use adb shell getprop command and grep specific info about your current device, For additional information you can read documentation: Android Debug Bridge documentation

    I added some examples below:

    1. language - adb shell getprop | grep language

    [persist.sys.language]: [en]

    [ro.product.locale.language]: [en]

    1. boot complete ( device ready after reset) - adb shell getprop | grep boot_completed

    [sys.boot_completed]: 1

    1. device model - adb shell getprop | grep model

    [ro.product.model]: [Nexus 4]

    1. sdk version - adb shell getprop | grep sdk

    [ro.build.version.sdk]: [22]

    1. time zone - adb shell getprop | grep timezone

    [persist.sys.timezone]: [Asia/China]

    1. serial number - adb shell getprop | grep serialno

    [ro.boot.serialno]: [1234567]

提交回复
热议问题