summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMihail Zenkov <mihail.zenkov@gmail.com>2015-02-15 00:26:02 +0000
committerMichael Giacomelli <giac2000@hotmail.com>2015-06-02 02:04:34 +0200
commit3e5e9cf7d7daaf5db194040662ff3d6e97edd116 (patch)
tree87d4abafc86c7285bb4865835f551199a52271ad
parent2ec6fbc827b559847b4f0d54d44de5299b8ab6cc (diff)
downloadrockbox-3e5e9cf.tar.gz
rockbox-3e5e9cf.zip
AS3543: Fix recording volume setting and voice
Fix regressions introduced by 42219b6e7 Change-Id: I1f3edb5f269f60e9431b45a43c4370836ecac733
-rw-r--r--firmware/drivers/audio/as3514.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/firmware/drivers/audio/as3514.c b/firmware/drivers/audio/as3514.c
index 6cad8259f7..11eb14cf75 100644
--- a/firmware/drivers/audio/as3514.c
+++ b/firmware/drivers/audio/as3514.c
@@ -299,7 +299,8 @@ void audiohw_set_volume(int vol_l, int vol_r)
}
#ifdef HAVE_AS3543
- if (!(as3514_regs[AS3514_HPH_OUT_R] & 0x40)) { /*if not radio or recording*/
+ /*if not radio or recording*/
+ if (!(as3514_regs[AS3514_AUDIOSET1] & (AUDIOSET1_ADC_on | AUDIOSET1_LIN1_on))) {
if (!hph_l || !hph_r) { /*if volume higher, disable the mixer to slightly improve noise*/
as3514_write(AS3514_AUDIOSET1, AUDIOSET1_DAC_on | AUDIOSET1_DAC_GAIN_on);
as3514_write(AS3514_AUDIOSET2, AUDIOSET2_AGC_off | AUDIOSET2_HPH_QUALITY_LOW_POWER);
@@ -484,7 +485,7 @@ void audiohw_set_monitor(bool enable)
{
if (enable) {
#ifdef HAVE_AS3543
- as3514_write_masked(AS3514_HPH_OUT_R, HPH_OUT_R_HP_OUT_LINE, HPH_OUT_R_HP_OUT_MASK);
+ as3514_write_masked(AS3514_HPH_OUT_R, HPH_OUT_R_HP_OUT_SUM, HPH_OUT_R_HP_OUT_MASK);
#endif
/* select either LIN1 or LIN2 */
as3514_write_masked(AS3514_AUDIOSET1, AUDIOSET1_LIN_on,