twilio / voice-quickstart-android

Quickstart app for the Voice Android SDK
https://www.twilio.com/docs/api/voice-sdk/android/getting-started
MIT License
184 stars 140 forks source link

Volume Low during call to PSTN #562

Closed husseinamar closed 7 months ago

husseinamar commented 1 year ago

Hello, first of all thank you all for your efforts in improving the SDK.

We have recently implemented the SDK into an app and have been going well.

The problem: Upon testing the app by making a call to a PSTN from the app, we noticed that the volume is quite low, even more so when using headphones. The volume is low on both sides. So both the caller and the callee have reported low volume compared to using WhatsApp Call or the native call app.

We have already tried using transient gain as suggested by the documentation and in issue #530. The problem has occurred on different Android devices and using different headphones (also different brands). One of the devices is a Xiaomi Redmi Note 11, tried with Android 11 and also Android 12.

Here are some of the Call SIDs:

afalls-twilio commented 10 months ago

@husseinamar Thank you for the report, sorry about the delay. Lets see what happens when we increase the system volume on the receiving device. Incoming PSTN calls are handled by a different volume system outside of our sdk, usually. When a PSTN call is in progress, press the volume key on the side of the device, and see if a different volume slider comes up.

Another suggestion is to progromaticly increase the PSTN call volume. Here is an example...

AudioManager audioManager = (AudioManager)getSystemService(Context.AUDIO_SERVICE);
audioManager.setStreamVolume(AudioManager.STREAM_VOICE_CALL, 20, 0);

Taken from here

afalls-twilio commented 7 months ago

closing due to inactivity

husseinamar commented 4 months ago

@husseinamar Thank you for the report, sorry about the delay. Lets see what happens when we increase the system volume on the receiving device. Incoming PSTN calls are handled by a different volume system outside of our sdk, usually. When a PSTN call is in progress, press the volume key on the side of the device, and see if a different volume slider comes up.

Another suggestion is to progromaticly increase the PSTN call volume. Here is an example...

AudioManager audioManager = (AudioManager)getSystemService(Context.AUDIO_SERVICE);
audioManager.setStreamVolume(AudioManager.STREAM_VOICE_CALL, 20, 0);

Taken from here

Thank you for the response @afalls-twilio, will give it a try. We have already tried increasing the volume mid-call on both the receiving end as well as the caller end. Receiving end is the PSTN, while the caller is from the app that uses the SDK. The volume slider is always the same.