zoukankan      html  css  js  c++  java
  • Genymotion shell

    Genymotion provides a shell that enables you to script the modification of sensor states.

    Command line options
    • -h: print help
    • -r ip_address: connect to specific Genymotion virtual device
    • -c "command": execute the given command in Genymotion Shell environment and return
    • -f file: execute the content of the file. Each command per line
    Available commands
    • battery getmode
      Get the current battery mode of the selected virtual device. The mode can only be:
      • host: The virtual battery reflect the host battery (if exists)
      • manual: In this mode, you can set the level and status battery values
    • battery setmode
      Set the battery mode. The mode can only be:
      • host: The virtual battery reflect the host battery (if exists)
      • manual: In this mode, you can set the level and status battery values
    • battery getlevel
      Get the current battery amount of power. The value can only be between 0% and 100%.
      If the battery mode is "host", the returned value is the host value.
    • battery setlevel
      Set the current battery amount of power. The value can only be between 0% and 100%.
      Set the battery level force the "manual" mode: if the last mode was "host", then it's turned to "manual"
    • battery getstatus
      Get the current battery status. There are 4 possible status:
      • Discharging: The power supply is disconnected and the battery is discharging.
      • Charging: The power supply is connected and the battery is charging.
      • Full: The battery is full.
      • Unknown: Sometimes, the battery status cannot be established, it happens when there is no host battery.
    • battery setstatus
      Set the current battery status. There are 4 possible status:
      • Discharging: The power supply is disconnected and the battery is discharging.
      • Charging: The power supply is connected and the battery is charging.
      • Full: The battery is full.
      • Unknown: Sometimes, the battery status cannot be established, it happens when there is no host battery.
    • devices list
      List available Genymotion virtual devices and provides details like current states or IP address.
    • devices ping
      Send a ping message to check if virtual device if responding
    • devices refresh
      Refresh Genymotion virtual device list. Use it to keep the list up-to-date.
    • devices select
      Select the Genymotion virtual device you want to interact with.
    • devices show
      List available Genymotion virtual devices and provides details like current states or IP address
    • devices factoryreset
      Factory reset virtual device (add keyword force at the end to avoid warning message about data loss)
    • gps activate
      Activate the GPS sensor (if not already activated)
    • gps desactivate
      Desactivate the GPS sensor (if activated)
    • gps getlatitude
      Return current latitude (if GPS is activated AND already has a latitude) or 0
    • gps setlatitude
      Set latitude (and activate GPS if not already activated)
    • gps getlongitude
      Return current longitude (if GPS is activated AND already has a longitude) or 0
    • gps setlongitude
      Set longitude (and activate GPS if not already activated)
    • gps getaltitude
      Return current altitude (if GPS is activated AND already has a altitude) or 0
    • gps setaltitude
      Set altitude (and activate GPS if not already activated)
    • gps getaccuracy
      Return current accuracy in meters (if GPS is activated AND already has a accuracy) or 0
    • gps setaccuracy
      Set accuracy (and activate GPS if not already activated)
    • gps getorientation
      Return current orientation in degrees (if GPS is activated AND already has a orientation) or 0
    • gps setorientation
      Set orientation (and activate GPS if not already activated)
    • rotation setangle
      Set the rotation angle of the virtual device.
    • genymotion capabilities
      Get Genymotion capabilities (gps, webcam, remote-control, ...) of selected virtual device.
    • genymotion clearcache
      Clear temporary downloaded files and logs.
    • genymotion version
      Get Genymotion version of selected virtual device.
    • genymotion license
      Get Genymotion license (type, validity, ...).
    • android version
      Get Android version of selected virtual device.
    • android getandroidid
      Get Android ID of selected virtual device (available only with Indie or Business license).
    • android setandroidid
      Set Android ID of selected virtual device (available only with Indie or Business license).
      Warning: if several users exist on the Android system, Android ID will only be set for the first user, not for all.
      Two kind of values are accepted:
      • random: generate a random Android ID.
      • custom value (must be 16 hexadecimal digits long).
    • android getdeviceid
      Get Device ID (IMEI/MEID number) of selected virtual device (available only with Indie or Business license).
    • android setdeviceid
      Set Device ID (IMEI/MEID number) of selected virtual device (available only with Indie or Business license).
      Three kind of values are accepted:
      • none: set an empty Device ID.
      • random: generate a random Device ID.
      • custom value (alphanumeric characters, point, dash, underscore).
    • build number
      Get Genymotion Shell build number
    • help
      Prompt the help.
    • pause
      Pause execution (in number of seconds).
    • version
      Get Genymotion Shell version.
    • exit or quit
      Close Genymotion Shell.
  • 相关阅读:
    Oracle Exadata和Exalogic利弊分析
    几个经常使用的正则验证
    開始开发 Dashboard Widget【翻译】文件夹
    j2ee 框架搭建所需jar包的作用
    【jQuery】复选框的批量处理:全选、非全选
    将 Android* x86 NDK 用于 Eclipse* 并移植 NDK 演示样例应用
    Socket connect error 99(Cannot assign requested address)
    解决w3wp.exe占用CPU和内存问题
    解决w3wp.exe占用CPU和内存问题
    解决w3wp.exe占用CPU和内存问题
  • 原文地址:https://www.cnblogs.com/ikaka/p/3572903.html
Copyright © 2011-2022 走看看