Make incoming call in Android emulator without command code

二次信任 提交于 2019-12-11 07:52:32

问题


I'm trying to develop a small app that will be registered on PhoneStateListener and do some magic over incoming and outgoing calls monitor. For debugging purposes, I need to trigger onCallStateChanged(...) event from outside of phone, not perform real incoming voice call.

Is it possible to do this somehow with sending phone number to debugged app without command line code?


回答1:


create one more emulator on avd machine. You can find the emulator number from top of the emulator. Eg. 5554 this number is like phone number you can enter the emulator this number(5554 or 5556 or somting) and make a incoming call.

enjoy ...




回答2:


Just follow Go to Window ===> Open Perspective & choose DDMS

In DDMS click on Emulator Control then select Voice and write number of another emulator on which You want to call. and then click on call .

You can find another emulator number from top of the emulator.

Hope it will helps you.




回答3:


You can use DDMS perspective in eclipse for initiating dummy calls , message etc

You can see DDMS perspective on top right corner if you do not see it

Go to Window ===> Open Perspective & choose DDMS




回答4:


Try one more emulator. You can find the emulator number from top of the emulator. Eg. 5556



来源:https://stackoverflow.com/questions/18460621/make-incoming-call-in-android-emulator-without-command-code

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!