Android, phone call audio stream via wlan

Posted by moppel on Stack Overflow See other posts from Stack Overflow or by moppel
Published on 2010-03-22T13:17:49Z Indexed on 2010/03/22 13:21 UTC
Read the original article Hit count: 259

Filed under:
|
|

I am planning on developing my specific voip app for android.

Here's the scenario: when a phone call occurs I want to hear the person who's calling on my local pc speakers and I want to speak to him via my own pc microphone / headset. So I need to send the audio stream of both me and the person I am talking to via the wlan network.

Something like this:

...
onCallStateChanged(int state, String phoneNumber){
 while(state == PhoneListener.CALL_STATE_OFFHOOK){ //while phone call is happaning
  //send incoming speech via wlan to pc
  //receive audiostream from pc microphone and direct it to the phone call
 }
}
...

Is this possible with the current Android API? (Actually it should be since voip apps are available in the market) I did some research in the Android API and all I found was the AudioManager which has constant named

public static final int  STREAM_VOICE_CALL; //The audio stream for phone calls 

But I don't know how to use it our how it should give me access to the actual audiostreams which I can send via network. How do I manage to do this?

The connection would be realised by TCP sockets.

© Stack Overflow or respective owner

Related posts about android

Related posts about voip