问题
With Android APIs, can I simulate/create an incoming call? This is not for testing purposes. I actually want my app to call the phone itself and have it ring.
回答1:
In order to create a "mock" incoming call, you would need to broadcast the intent associated with this. Some info on how to handle an incoming call can be found here. You will instead need to create the broadcast intent on your own, and pass in the necessary extras. An example of creating an intent with extras, and how to handle them in your app, can be found here.
来源:https://stackoverflow.com/questions/9050658/with-android-apis-can-i-simulate-create-an-incoming-call