Open mathias5r opened 3 years ago
When module is mounted, the audio volume control (slider) is changed to RING mode and the volume buttons don't influence the audio volume at all.
The code below changes the audio volume control and add delays when the audio route is switched.
mAudioManager.setMode(AudioManager.MODE_IN_COMMUNICATION);
Switch audio route to earpiece through MediaPlayer.
Problem
When module is mounted, the audio volume control (slider) is changed to RING mode and the volume buttons don't influence the audio volume at all.
Cause
The code below changes the audio volume control and add delays when the audio route is switched.
Solution
Switch audio route to earpiece through MediaPlayer.