undo some changes of my last patch... should fix wm8751 based targets
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17286 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
9c0abbf838
commit
a6100fb5ee
2 changed files with 15 additions and 3 deletions
|
@ -79,7 +79,7 @@ static int tone_tenthdb2hw(int value)
|
|||
/* -6.0db..+0db..+9.0db step 1.5db - translate -60..+0..+90 step 15
|
||||
to 10..6..0 step -1.
|
||||
*/
|
||||
value = (10 - (value + 60) / 15) / 10;
|
||||
value = 10 - (value + 60) / 15;
|
||||
|
||||
if (value == 6)
|
||||
value = 0xf; /* 0db -> off */
|
||||
|
|
|
@ -35,6 +35,10 @@
|
|||
#endif
|
||||
#endif
|
||||
|
||||
/* TODO
|
||||
* find a nice way to handle 1.5db steps -> see wm8751 ifdef in sound_set_bass/treble
|
||||
*/
|
||||
|
||||
#if !defined(VOLUME_MIN) && !defined(VOLUME_MAX)
|
||||
#warning define for VOLUME_MIN and VOLUME_MAX is missing
|
||||
#define VOLUME_MIN -400
|
||||
|
@ -370,7 +374,11 @@ void sound_set_bass(int value)
|
|||
#endif
|
||||
|
||||
#if (CONFIG_CODEC != MAS3587F) && (CONFIG_CODEC != MAS3539F)
|
||||
current_bass = value * 10;
|
||||
#if defined(HAVE_WM8751)
|
||||
current_bass = value;
|
||||
#else
|
||||
current_bass = value * 10;
|
||||
#endif
|
||||
set_prescaled_volume();
|
||||
#endif
|
||||
}
|
||||
|
@ -387,7 +395,11 @@ void sound_set_treble(int value)
|
|||
#endif
|
||||
|
||||
#if (CONFIG_CODEC != MAS3587F) && (CONFIG_CODEC != MAS3539F)
|
||||
current_treble = value * 10;
|
||||
#if defined(HAVE_WM8751)
|
||||
current_treble = value;
|
||||
#else
|
||||
current_treble = value * 10;
|
||||
#endif
|
||||
set_prescaled_volume();
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue