diff options
-rw-r--r-- | audio/audio_hw.c | 14 | ||||
-rw-r--r-- | configs/tiny_hw.xml | 8 |
2 files changed, 17 insertions, 5 deletions
diff --git a/audio/audio_hw.c b/audio/audio_hw.c index 762db0e..c1471b2 100644 --- a/audio/audio_hw.c +++ b/audio/audio_hw.c @@ -598,6 +598,18 @@ static void select_mode(struct m0_audio_device *adev) adev->in_call = 0; ril_set_call_clock_sync(&adev->ril, SOUND_CLOCK_STOP); end_call(adev); + //Force Input Standby + adev->in_device = AUDIO_DEVICE_NONE; + + ALOGD("%s: set voicecall route: voicecall_default_disable", __func__); + set_bigroute_by_array(adev->mixer, voicecall_default_disable, 1); + ALOGD("%s: set voicecall route: default_input_disable", __func__); + set_bigroute_by_array(adev->mixer, default_input_disable, 1); + ALOGD("%s: set voicecall route: headset_input_disable", __func__); + set_bigroute_by_array(adev->mixer, headset_input_disable, 1); + ALOGD("%s: set voicecall route: bt_disable", __func__); + set_bigroute_by_array(adev->mixer, bt_disable, 1); + force_all_standby(adev); select_output_device(adev); select_input_device(adev); @@ -3081,7 +3093,7 @@ static int adev_open(const hw_module_t* module, const char* name, pthread_mutex_lock(&adev->lock); adev->mode = AUDIO_MODE_NORMAL; adev->out_device = AUDIO_DEVICE_OUT_SPEAKER; - adev->in_device = AUDIO_DEVICE_IN_BUILTIN_MIC & ~AUDIO_DEVICE_BIT_IN; + adev->in_device = AUDIO_DEVICE_NONE; select_devices(adev); adev->pcm_modem_dl = NULL; diff --git a/configs/tiny_hw.xml b/configs/tiny_hw.xml index 64fae98..b84713b 100644 --- a/configs/tiny_hw.xml +++ b/configs/tiny_hw.xml @@ -275,9 +275,9 @@ We are able to have most of our routing static so do that <path name="on"> <ctl name="Main Mic Switch" val="1"/> <ctl name="MainMicBias Mode" val="1"/> - <ctl name="IN2L Volume" val="28"/> + <ctl name="IN2L Volume" val="26"/> <ctl name="MIXINL IN2L Switch" val="1"/> - <ctl name="MIXINL IN2L Volume" val="1"/> + <ctl name="MIXINL IN2L Volume" val="0"/> <ctl name="AIF1ADCL Source" val="0"/> <ctl name="AIF1ADC1 HPF Mode" val="0"/> <ctl name="AIF1ADC1 HPF Switch" val="1"/> @@ -295,9 +295,9 @@ We are able to have most of our routing static so do that <path name="on"> <ctl name="Sub Mic Switch" val="1"/> <ctl name="SubMicBias Mode" val="1"/> - <ctl name="IN1R Volume" val="28"/> + <ctl name="IN1R Volume" val="27"/> <ctl name="MIXINR IN1R Switch" val="1"/> - <ctl name="MIXINR IN1R Volume" val="1"/> + <ctl name="MIXINR IN1R Volume" val="0"/> <ctl name="AIF1ADCR Source" val="1"/> <ctl name="AIF1ADC1 HPF Mode" val="1"/> <ctl name="AIF1ADC1 HPF Switch" val="1"/> |