1

The problem

I'm working on an Android VoIP application. I have to signal an incoming call to the cars' navigation system when the phone is connected to them via Bluetooth.

What I did so far

Beside a lot of searching and reading, and trial and errors this is the current state:

When there is an incoming call (SIP INVITE was received by the app) the following happens:

  • set the mode in AudioManager to RINGING: audioManager.setMode(AudioManager.MODE_RINGING);
  • request audio focus:
    audioManager.requestAudioFocus(this, AudioManager.STREAM_RING, AudioManager.AUDIOFOCUS_GAIN);
  • enabled and started bluetoothSco:
    audioManager.setBluetoothScoOn(true);
    audioManager.startBluetoothSco();

What happens

In the car the in call screen is displayed directly, instead of the incoming call. So, the user can only hang up the call, and cannot answer since the answer button is not displayed.

I'm guessing that I'm not signalling correctly the state even though the JavaDoc on AudioManager says that the RINGING mode is used for signalling such a thing.

Please let me know if you have any ideas on how to solve this issue.

Community
  • 1
  • 1
Robert
  • 15
  • 5

0 Answers0