2 * This file is only included exactly once!
4 * The tables here are derived from the tas3004 datasheet,
5 * modulo typo corrections and some smoothing...
8 #define TAS3004_TREBLE_MIN 0
9 #define TAS3004_TREBLE_MAX 72
10 #define TAS3004_BASS_MIN 0
11 #define TAS3004_BASS_MAX 72
12 #define TAS3004_TREBLE_ZERO 36
13 #define TAS3004_BASS_ZERO 36
15 static u8 tas3004_treble_table[] = {
91 static inline u8 tas3004_treble(int idx)
93 return tas3004_treble_table[idx];
96 /* I only save the difference here to the treble table
97 * so that the binary is smaller...
98 * I have also ignored completely differences of
101 static s8 tas3004_bass_diff_to_treble[] = {
102 2, /* 7 dB, offset 50 */
127 static inline u8 tas3004_bass(int idx)
129 u8 result = tas3004_treble_table[idx];
132 result += tas3004_bass_diff_to_treble[idx-50];