Genymotion shell

6718 단어 Genymotion
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.
  • 좋은 웹페이지 즐겨찾기