I bought a single-channel Bluetooth headset. I didn't expect to have to make a phone call, but I couldn't listen to music. But when I call the phone and play the music again, the sound will come out of the Bluetooth headset. Can I write a location that controls the audio output? After searching online, there are two pieces of software that can be used: Super mono free trial and supermonofroyofreetrial. They are free of charge, but they are restricted in use. In a rage, they are cracked, the implementation code is as follows:
Output to Bluetooth headset:
Audiomanager mam = (audiomanager) getsystemservice (context. audio_service );
Mam. setmode (audiomanager. mode_in_call );
Mam. setincluthscoon (true );
Mam. startbluw.thsco ();
Output to mobile phone:
Audiomanager mam = (audiomanager) getsystemservice (context. audio_service );
Mam. setmode (audiomanager. mode_normal );
Mam. setincluthscoon (false );
Mam. stop1_thsco ();
Add capabilities in androidmanifest. xml:
<Uses-Permission Android: Name = "android. Permission. modify_audio_settings"/>
Several lines of code. The output to a Bluetooth headset may be delayed.
Set the volume to the Control Source
Setvolumecontrolstream (audiomanager. stream_music );