我怎样才能运行ADB壳Android摄像头应用程序? [英] How can I run Android camera application from adb shell?
本文介绍了我怎样才能运行ADB壳Android摄像头应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何运行从亚行的shell Android摄像头程序?
我知道,我应该使用时,但我不知道是什么命令,我应该准确地输入
How can I run android camera program from adb shell?
I know that I should use am but I do not know what command should I exactly enter
我用这样的:
am start -a android.intent.action.MAIN -n com.android.camera
但它没有工作!
But it didn't work!
推荐答案
另外,你可以启动相机2其它方式
Alternatively, you can start the camera in 2 other ways
- 拍摄模式:
ADB壳我开始-a android.media.action.IMAGE_CAPTURE
- 在视频拍摄模式:
ADB壳我开始-a android.media.action.VIDEO_CAPTURE
- Image capture mode:
adb shell "am start -a android.media.action.IMAGE_CAPTURE"
- Video capture mode:
adb shell "am start -a android.media.action.VIDEO_CAPTURE"
其他信息
- 要重点:
ADB壳输入KeyEvent的主要code_FOCUS
- 要拍照或录音停止/启动:
ADB壳输入KeyEvent的主要code_CAMERA
- To focus:
adb shell "input keyevent KEYCODE_FOCUS"
- To take a photo or start/stop recording:
adb shell "input keyevent KEYCODE_CAMERA"
其他笔记
F键code字符串,例如KEY code_CAMERA,不工作,查找从API说明的恒定值。例如:<一href="http://developer.android.com/reference/android/view/KeyEvent.html#KEY$c$c_CAMERA">KEY$c$c_CAMERA
f the keycode string e.g KEYCODE_CAMERA, does not work, lookup the constant value from the API description. Example: KEYCODE_CAMERA
KEYCODE_CAMERA: Added in API level 1
Constant Value: 27 (0x0000001b)
这篇关于我怎样才能运行ADB壳Android摄像头应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文