diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/drivers/audio/as3514.c | 85 | ||||
-rw-r--r-- | firmware/export/as3514.h | 23 | ||||
-rw-r--r-- | firmware/export/config/sansaclipplus.h | 15 | ||||
-rw-r--r-- | firmware/export/config/sansaclipv2.h | 14 | ||||
-rw-r--r-- | firmware/export/config/sansafuzev2.h | 10 |
5 files changed, 79 insertions, 68 deletions
diff --git a/firmware/drivers/audio/as3514.c b/firmware/drivers/audio/as3514.c index 11adddc0f1..9255828f75 100644 --- a/firmware/drivers/audio/as3514.c +++ b/firmware/drivers/audio/as3514.c | |||
@@ -38,12 +38,29 @@ | |||
38 | * as3543 , as used in the as3525v2 targets | 38 | * as3543 , as used in the as3525v2 targets |
39 | */ | 39 | */ |
40 | 40 | ||
41 | #if CONFIG_CPU == AS3525 | ||
41 | /* AMS Sansas based on the AS3525 use the LINE2 input for the analog radio | 42 | /* AMS Sansas based on the AS3525 use the LINE2 input for the analog radio |
42 | signal instead of LINE1 */ | 43 | signal instead of LINE1 */ |
43 | #if CONFIG_CPU == AS3525 | 44 | #define AS3514_LINE_IN_R AS3514_LINE_IN2_R |
44 | #define LINE_INPUT 2 | 45 | #define AS3514_LINE_IN_L AS3514_LINE_IN2_L |
45 | #else | 46 | #define ADC_R_ADCMUX_LINE_IN ADC_R_ADCMUX_LINE_IN2 |
46 | #define LINE_INPUT 1 | 47 | #define AUDIOSET1_LIN_on AUDIOSET1_LIN2_on |
48 | |||
49 | #elif CONFIG_CPU == AS3525v2 | ||
50 | /* There is only 1 pair of registers on AS3543, the line input is selectable in | ||
51 | LINE_IN_R register */ | ||
52 | #define AS3514_LINE_IN_R AS3514_LINE_IN1_R | ||
53 | #define AS3514_LINE_IN_L AS3514_LINE_IN1_L | ||
54 | #define ADC_R_ADCMUX_LINE_IN ADC_R_ADCMUX_LINE_IN2 | ||
55 | #define AUDIOSET1_LIN_on AUDIOSET1_LIN1_on | ||
56 | |||
57 | #else /* PP use line1 */ | ||
58 | |||
59 | #define AS3514_LINE_IN_R AS3514_LINE_IN1_R | ||
60 | #define AS3514_LINE_IN_L AS3514_LINE_IN1_L | ||
61 | #define ADC_R_ADCMUX_LINE_IN ADC_R_ADCMUX_LINE_IN1 | ||
62 | #define AUDIOSET1_LIN_on AUDIOSET1_LIN1_on | ||
63 | |||
47 | #endif | 64 | #endif |
48 | 65 | ||
49 | const struct sound_settings_info audiohw_settings[] = { | 66 | const struct sound_settings_info audiohw_settings[] = { |
@@ -177,22 +194,22 @@ void audiohw_preinit(void) | |||
177 | as3514_write(AS3514_AUDIOSET3, AUDIOSET3_HPCM_off); | 194 | as3514_write(AS3514_AUDIOSET3, AUDIOSET3_HPCM_off); |
178 | #endif | 195 | #endif |
179 | 196 | ||
180 | #if CONFIG_CPU != AS3525v2 | 197 | #ifdef HAVE_AS3543 |
198 | as3514_clear(AS3543_DAC_IF, 0x80); | ||
199 | as3514_set(AS3514_LINE_IN1_R, LINE_IN_R_LINE_SELECT); /* Line 2 */ | ||
200 | #else | ||
181 | /* Mute and disable speaker */ | 201 | /* Mute and disable speaker */ |
182 | as3514_write(AS3514_LSP_OUT_R, LSP_OUT_R_SP_OVC_TO_256MS | 0x00); | 202 | as3514_write(AS3514_LSP_OUT_R, LSP_OUT_R_SP_OVC_TO_256MS | 0x00); |
183 | as3514_write(AS3514_LSP_OUT_L, LSP_OUT_L_SP_MUTE | 0x00); | 203 | as3514_write(AS3514_LSP_OUT_L, LSP_OUT_L_SP_MUTE | 0x00); |
184 | #else | ||
185 | as3514_clear(AS3543_DAC_IF, 0x80); | ||
186 | as3514_set(AS3514_LINE_IN1_R, 1<<6); // Select Line-in 2 | ||
187 | #endif | 204 | #endif |
188 | 205 | ||
189 | #if CONFIG_CPU != AS3525v2 | 206 | #ifdef HAVE_AS3543 |
207 | as3514_write(AS3514_HPH_OUT_R, (0<<7) /* out */ | HPH_OUT_R_HP_OUT_DAC | | ||
208 | 0x00); | ||
209 | #else | ||
190 | /* Set headphone over-current to 0, Min volume */ | 210 | /* Set headphone over-current to 0, Min volume */ |
191 | as3514_write(AS3514_HPH_OUT_R, | 211 | as3514_write(AS3514_HPH_OUT_R, |
192 | HPH_OUT_R_HP_OVC_TO_0MS | 0x00); | 212 | HPH_OUT_R_HP_OVC_TO_0MS | 0x00); |
193 | #else | ||
194 | as3514_write(AS3514_HPH_OUT_R, (0<<7) /* out */ | HPH_OUT_R_HP_OUT_DAC | | ||
195 | 0x00); | ||
196 | #endif | 213 | #endif |
197 | /* Headphone ON, MUTE, Min volume */ | 214 | /* Headphone ON, MUTE, Min volume */ |
198 | as3514_write(AS3514_HPH_OUT_L, | 215 | as3514_write(AS3514_HPH_OUT_L, |
@@ -211,8 +228,10 @@ void audiohw_preinit(void) | |||
211 | 228 | ||
212 | /* M1_Sup_off */ | 229 | /* M1_Sup_off */ |
213 | as3514_set(AS3514_MIC1_L, MIC1_L_M1_SUP_off); | 230 | as3514_set(AS3514_MIC1_L, MIC1_L_M1_SUP_off); |
231 | #ifndef HAVE_AS3543 | ||
214 | /* M2_Sup_off */ | 232 | /* M2_Sup_off */ |
215 | as3514_set(AS3514_MIC2_L, MIC2_L_M2_SUP_off); | 233 | as3514_set(AS3514_MIC2_L, MIC2_L_M2_SUP_off); |
234 | #endif | ||
216 | } | 235 | } |
217 | 236 | ||
218 | void audiohw_postinit(void) | 237 | void audiohw_postinit(void) |
@@ -257,12 +276,8 @@ void audiohw_set_master_vol(int vol_l, int vol_r) | |||
257 | as3514_write_masked(AS3514_DAC_R, mix_r, AS3514_VOL_MASK); | 276 | as3514_write_masked(AS3514_DAC_R, mix_r, AS3514_VOL_MASK); |
258 | as3514_write_masked(AS3514_DAC_L, mix_l, AS3514_VOL_MASK); | 277 | as3514_write_masked(AS3514_DAC_L, mix_l, AS3514_VOL_MASK); |
259 | #if defined(HAVE_RECORDING) || defined(HAVE_FMRADIO_IN) | 278 | #if defined(HAVE_RECORDING) || defined(HAVE_FMRADIO_IN) |
260 | as3514_write_masked((LINE_INPUT == 1) ? AS3514_LINE_IN1_R : | 279 | as3514_write_masked(AS3514_LINE_IN_R, mix_r, AS3514_VOL_MASK); |
261 | AS3514_LINE_IN2_R, | 280 | as3514_write_masked(AS3514_LINE_IN_L, mix_l, AS3514_VOL_MASK); |
262 | mix_r, AS3514_VOL_MASK); | ||
263 | as3514_write_masked((LINE_INPUT == 1) ? AS3514_LINE_IN1_L : | ||
264 | AS3514_LINE_IN2_L, | ||
265 | mix_l, AS3514_VOL_MASK); | ||
266 | #endif | 281 | #endif |
267 | as3514_write_masked(AS3514_HPH_OUT_R, hph_r, AS3514_VOL_MASK); | 282 | as3514_write_masked(AS3514_HPH_OUT_R, hph_r, AS3514_VOL_MASK); |
268 | as3514_write_masked(AS3514_HPH_OUT_L, hph_l, AS3514_VOL_MASK); | 283 | as3514_write_masked(AS3514_HPH_OUT_L, hph_l, AS3514_VOL_MASK); |
@@ -278,13 +293,13 @@ void audiohw_mute(bool mute) | |||
278 | { | 293 | { |
279 | if (mute) { | 294 | if (mute) { |
280 | as3514_set(AS3514_HPH_OUT_L, HPH_OUT_L_HP_MUTE); | 295 | as3514_set(AS3514_HPH_OUT_L, HPH_OUT_L_HP_MUTE); |
281 | #if CONFIG_CPU == AS3525v2 | 296 | #ifdef HAVE_AS3543 |
282 | as3514_set(AS3543_DAC_IF, 0x80); | 297 | as3514_set(AS3543_DAC_IF, 0x80); |
283 | #endif | 298 | #endif |
284 | 299 | ||
285 | } else { | 300 | } else { |
286 | as3514_clear(AS3514_HPH_OUT_L, HPH_OUT_L_HP_MUTE); | 301 | as3514_clear(AS3514_HPH_OUT_L, HPH_OUT_L_HP_MUTE); |
287 | #if CONFIG_CPU == AS3525v2 | 302 | #ifdef HAVE_AS3543 |
288 | as3514_clear(AS3543_DAC_IF, 0x80); | 303 | as3514_clear(AS3543_DAC_IF, 0x80); |
289 | #endif | 304 | #endif |
290 | } | 305 | } |
@@ -307,7 +322,7 @@ void audiohw_close(void) | |||
307 | as3514_clear(AS3514_HPH_OUT_L, HPH_OUT_L_HP_ON); | 322 | as3514_clear(AS3514_HPH_OUT_L, HPH_OUT_L_HP_ON); |
308 | as3514_write(AS3514_AUDIOSET1, 0x0); | 323 | as3514_write(AS3514_AUDIOSET1, 0x0); |
309 | 324 | ||
310 | #if CONFIG_CPU == AS3525v2 | 325 | #ifdef HAVE_AS3543 |
311 | as3514_set(AS3543_DAC_IF, 0x80); | 326 | as3514_set(AS3543_DAC_IF, 0x80); |
312 | #endif | 327 | #endif |
313 | 328 | ||
@@ -336,15 +351,11 @@ void audiohw_enable_recording(bool source_mic) | |||
336 | as3514_clear(AS3514_MIC1_R, MIC1_R_M1_AGC_off); | 351 | as3514_clear(AS3514_MIC1_R, MIC1_R_M1_AGC_off); |
337 | } else { | 352 | } else { |
338 | /* ADCmux = Line_IN1 or Line_IN2 */ | 353 | /* ADCmux = Line_IN1 or Line_IN2 */ |
339 | as3514_write_masked(AS3514_ADC_R, | 354 | as3514_write_masked(AS3514_ADC_R, ADC_R_ADCMUX_LINE_IN, |
340 | (LINE_INPUT == 1) ? ADC_R_ADCMUX_LINE_IN1 : | ||
341 | ADC_R_ADCMUX_LINE_IN2, | ||
342 | ADC_R_ADCMUX); | 355 | ADC_R_ADCMUX); |
343 | 356 | ||
344 | /* LIN1_or LIN2 on, rest off */ | 357 | /* LIN1_or LIN2 on, rest off */ |
345 | as3514_write_masked(AS3514_AUDIOSET1, | 358 | as3514_write_masked(AS3514_AUDIOSET1, AUDIOSET1_LIN_on, |
346 | (LINE_INPUT == 1) ? AUDIOSET1_LIN1_on : | ||
347 | AUDIOSET1_LIN2_on, | ||
348 | AUDIOSET1_INPUT_MASK); | 359 | AUDIOSET1_INPUT_MASK); |
349 | } | 360 | } |
350 | 361 | ||
@@ -422,16 +433,12 @@ void audiohw_set_monitor(bool enable) | |||
422 | { | 433 | { |
423 | if (enable) { | 434 | if (enable) { |
424 | /* select either LIN1 or LIN2 */ | 435 | /* select either LIN1 or LIN2 */ |
425 | as3514_write_masked(AS3514_AUDIOSET1, | 436 | as3514_write_masked(AS3514_AUDIOSET1, AUDIOSET1_LIN_on, |
426 | (LINE_INPUT == 1) ? | ||
427 | AUDIOSET1_LIN1_on : AUDIOSET1_LIN2_on, | ||
428 | AUDIOSET1_LIN1_on | AUDIOSET1_LIN2_on); | 437 | AUDIOSET1_LIN1_on | AUDIOSET1_LIN2_on); |
429 | as3514_set((LINE_INPUT == 1) ? AS3514_LINE_IN1_R : AS3514_LINE_IN2_R, | 438 | as3514_set(AS3514_LINE_IN_R, LINE_IN1_R_LI1R_MUTE_off); |
430 | LINE_IN1_R_LI1R_MUTE_off); | 439 | as3514_set(AS3514_LINE_IN_L, LINE_IN1_L_LI1L_MUTE_off); |
431 | as3514_set((LINE_INPUT == 1) ? AS3514_LINE_IN1_L : AS3514_LINE_IN2_L, | ||
432 | LINE_IN1_L_LI1L_MUTE_off); | ||
433 | 440 | ||
434 | #if CONFIG_CPU == AS3525v2 | 441 | #ifdef HAVE_AS3543 |
435 | as3514_write_masked(AS3514_HPH_OUT_R, | 442 | as3514_write_masked(AS3514_HPH_OUT_R, |
436 | HPH_OUT_R_HP_OUT_LINE, HPH_OUT_R_HP_OUT_MASK); | 443 | HPH_OUT_R_HP_OUT_LINE, HPH_OUT_R_HP_OUT_MASK); |
437 | #endif | 444 | #endif |
@@ -440,12 +447,12 @@ void audiohw_set_monitor(bool enable) | |||
440 | /* turn off both LIN1 and LIN2 */ | 447 | /* turn off both LIN1 and LIN2 */ |
441 | as3514_clear(AS3514_LINE_IN1_R, LINE_IN1_R_LI1R_MUTE_off); | 448 | as3514_clear(AS3514_LINE_IN1_R, LINE_IN1_R_LI1R_MUTE_off); |
442 | as3514_clear(AS3514_LINE_IN1_L, LINE_IN1_L_LI1L_MUTE_off); | 449 | as3514_clear(AS3514_LINE_IN1_L, LINE_IN1_L_LI1L_MUTE_off); |
443 | #if CONFIG_CPU != AS3525v2 /* not in as3543 */ | 450 | #ifdef HAVE_AS3543 |
444 | as3514_clear(AS3514_LINE_IN2_R, LINE_IN2_R_LI2R_MUTE_off); | ||
445 | as3514_clear(AS3514_LINE_IN2_L, LINE_IN2_L_LI2L_MUTE_off); | ||
446 | #else | ||
447 | as3514_write_masked(AS3514_HPH_OUT_R, | 451 | as3514_write_masked(AS3514_HPH_OUT_R, |
448 | HPH_OUT_R_HP_OUT_DAC, HPH_OUT_R_HP_OUT_MASK); | 452 | HPH_OUT_R_HP_OUT_DAC, HPH_OUT_R_HP_OUT_MASK); |
453 | #else | ||
454 | as3514_clear(AS3514_LINE_IN2_R, LINE_IN2_R_LI2R_MUTE_off); | ||
455 | as3514_clear(AS3514_LINE_IN2_L, LINE_IN2_L_LI2L_MUTE_off); | ||
449 | #endif | 456 | #endif |
450 | as3514_clear(AS3514_AUDIOSET1, AUDIOSET1_LIN1_on | AUDIOSET1_LIN2_on); | 457 | as3514_clear(AS3514_AUDIOSET1, AUDIOSET1_LIN1_on | AUDIOSET1_LIN2_on); |
451 | } | 458 | } |
diff --git a/firmware/export/as3514.h b/firmware/export/as3514.h index afc982da39..2db28397f1 100644 --- a/firmware/export/as3514.h +++ b/firmware/export/as3514.h | |||
@@ -22,6 +22,8 @@ | |||
22 | #ifndef _AS3514_H | 22 | #ifndef _AS3514_H |
23 | #define _AS3514_H | 23 | #define _AS3514_H |
24 | 24 | ||
25 | #include "config.h" | ||
26 | |||
25 | extern int tenthdb2master(int db); | 27 | extern int tenthdb2master(int db); |
26 | 28 | ||
27 | extern void audiohw_set_master_vol(int vol_l, int vol_r); | 29 | extern void audiohw_set_master_vol(int vol_l, int vol_r); |
@@ -36,24 +38,32 @@ extern void audiohw_set_lineout_vol(int vol_l, int vol_r); | |||
36 | #define AS3514_LSP_OUT_L 0x05 | 38 | #define AS3514_LSP_OUT_L 0x05 |
37 | #define AS3514_MIC1_R 0x06 | 39 | #define AS3514_MIC1_R 0x06 |
38 | #define AS3514_MIC1_L 0x07 | 40 | #define AS3514_MIC1_L 0x07 |
41 | #ifndef HAVE_AS3543 | ||
39 | #define AS3514_MIC2_R 0x08 | 42 | #define AS3514_MIC2_R 0x08 |
40 | #define AS3514_MIC2_L 0x09 | 43 | #define AS3514_MIC2_L 0x09 |
44 | #endif | ||
41 | #define AS3514_LINE_IN1_R 0x0a | 45 | #define AS3514_LINE_IN1_R 0x0a |
42 | #define AS3514_LINE_IN1_L 0x0b | 46 | #define AS3514_LINE_IN1_L 0x0b |
47 | #ifndef HAVE_AS3543 | ||
43 | #define AS3514_LINE_IN2_R 0x0c | 48 | #define AS3514_LINE_IN2_R 0x0c |
44 | #define AS3514_LINE_IN2_L 0x0d | 49 | #define AS3514_LINE_IN2_L 0x0d |
50 | #endif | ||
45 | #define AS3514_DAC_R 0x0e | 51 | #define AS3514_DAC_R 0x0e |
46 | #define AS3514_DAC_L 0x0f | 52 | #define AS3514_DAC_L 0x0f |
47 | #define AS3514_ADC_R 0x10 | 53 | #define AS3514_ADC_R 0x10 |
48 | #define AS3514_ADC_L 0x11 | 54 | #define AS3514_ADC_L 0x11 |
49 | #define AS3543_DAC_IF 0x12 /* only in as3543 */ | 55 | #ifdef HAVE_AS3543 |
56 | #define AS3543_DAC_IF 0x12 | ||
57 | #endif | ||
50 | #define AS3514_AUDIOSET1 0x14 | 58 | #define AS3514_AUDIOSET1 0x14 |
51 | #define AS3514_AUDIOSET2 0x15 | 59 | #define AS3514_AUDIOSET2 0x15 |
52 | #define AS3514_AUDIOSET3 0x16 | 60 | #define AS3514_AUDIOSET3 0x16 |
53 | #define AS3517_USB_UTIL 0x17 /* only in as3517+ */ | 61 | #define AS3517_USB_UTIL 0x17 /* only in as3517+ */ |
54 | 62 | ||
55 | #define AS3543_BACKLIGHT 0x1b /* only in as3543 */ | 63 | #ifdef HAVE_AS3543 |
56 | #define AS3543_PMU_ENABLE 0x1c /* only in as3543 */ | 64 | #define AS3543_BACKLIGHT 0x1b |
65 | #define AS3543_PMU_ENABLE 0x1c | ||
66 | #endif | ||
57 | 67 | ||
58 | #define AS3514_PLLMODE 0x1d | 68 | #define AS3514_PLLMODE 0x1d |
59 | 69 | ||
@@ -161,6 +171,9 @@ extern void audiohw_set_lineout_vol(int vol_l, int vol_r); | |||
161 | /* Use AS3514_VOL_MASK */ | 171 | /* Use AS3514_VOL_MASK */ |
162 | 172 | ||
163 | /* LINE_IN1_R (0Ah) */ | 173 | /* LINE_IN1_R (0Ah) */ |
174 | #ifdef HAVE_AS3543 | ||
175 | #define LINE_IN_R_LINE_SELECT (0x1 << 6) | ||
176 | #endif | ||
164 | #define LINE_IN1_R_LI1R_MUTE_off (0x1 << 5) | 177 | #define LINE_IN1_R_LI1R_MUTE_off (0x1 << 5) |
165 | /* Use AS3514_VOL_MASK */ | 178 | /* Use AS3514_VOL_MASK */ |
166 | 179 | ||
@@ -201,8 +214,12 @@ extern void audiohw_set_lineout_vol(int vol_l, int vol_r); | |||
201 | /* Use AS3514_VOL_MASK */ | 214 | /* Use AS3514_VOL_MASK */ |
202 | 215 | ||
203 | /* ADC_L (11h) */ | 216 | /* ADC_L (11h) */ |
217 | #ifdef HAVE_AS3543 | ||
218 | #define ADC_L_ADC_MUTE_off (0x1 << 5) | ||
219 | #else | ||
204 | #define ADC_L_FS_2 (0x1 << 7) | 220 | #define ADC_L_FS_2 (0x1 << 7) |
205 | #define ADC_L_ADC_MUTE_off (0x1 << 6) | 221 | #define ADC_L_ADC_MUTE_off (0x1 << 6) |
222 | #endif | ||
206 | /* Use AS3514_VOL_MASK */ | 223 | /* Use AS3514_VOL_MASK */ |
207 | 224 | ||
208 | /* AUDIOSET1 (14h)*/ | 225 | /* AUDIOSET1 (14h)*/ |
diff --git a/firmware/export/config/sansaclipplus.h b/firmware/export/config/sansaclipplus.h index 310df3a115..462c0a76e8 100644 --- a/firmware/export/config/sansaclipplus.h +++ b/firmware/export/config/sansaclipplus.h | |||
@@ -16,19 +16,12 @@ | |||
16 | #define HAVE_HOTSWAP | 16 | #define HAVE_HOTSWAP |
17 | #endif | 17 | #endif |
18 | 18 | ||
19 | 19 | #define HW_SAMPR_CAPS SAMPR_CAP_ALL | |
20 | #if 0 /* disabled since there is no driver (yet) */ | ||
21 | |||
22 | #define HW_SAMPR_CAPS (SAMPR_CAP_44) | ||
23 | 20 | ||
24 | /* define this if you have recording possibility */ | 21 | /* define this if you have recording possibility */ |
25 | #define HAVE_RECORDING | 22 | #define HAVE_RECORDING |
26 | 23 | ||
27 | #define REC_SAMPR_CAPS (SAMPR_CAP_22) | 24 | #define REC_SAMPR_CAPS SAMPR_CAP_ALL |
28 | #define REC_FREQ_DEFAULT REC_FREQ_22 /* Default is not 44.1kHz */ | ||
29 | #define REC_SAMPR_DEFAULT SAMPR_22 | ||
30 | |||
31 | #endif | ||
32 | 25 | ||
33 | /* Define bitmask of input sources - recordable bitmask can be defined | 26 | /* Define bitmask of input sources - recordable bitmask can be defined |
34 | explicitly if different */ | 27 | explicitly if different */ |
@@ -104,9 +97,9 @@ | |||
104 | /* There is no hardware tone control */ | 97 | /* There is no hardware tone control */ |
105 | #define HAVE_SW_TONE_CONTROLS | 98 | #define HAVE_SW_TONE_CONTROLS |
106 | 99 | ||
107 | /* We're working on the assumption that the AS3525 has something | 100 | /* AS3514 or newer */ |
108 | similar to the AS3514 for audio codec etc */ | ||
109 | #define HAVE_AS3514 | 101 | #define HAVE_AS3514 |
102 | #define HAVE_AS3543 | ||
110 | 103 | ||
111 | /* define this if you have a real-time clock */ | 104 | /* define this if you have a real-time clock */ |
112 | #ifndef BOOTLOADER | 105 | #ifndef BOOTLOADER |
diff --git a/firmware/export/config/sansaclipv2.h b/firmware/export/config/sansaclipv2.h index d9f3cf2142..20196dc72f 100644 --- a/firmware/export/config/sansaclipv2.h +++ b/firmware/export/config/sansaclipv2.h | |||
@@ -9,18 +9,12 @@ | |||
9 | #define FIRMWARE_OFFSET_FILE_DATA 8 | 9 | #define FIRMWARE_OFFSET_FILE_DATA 8 |
10 | #define FIRMWARE_OFFSET_FILE_CRC 0 | 10 | #define FIRMWARE_OFFSET_FILE_CRC 0 |
11 | 11 | ||
12 | #if 0 /* disabled since there is no driver (yet) */ | 12 | #define HW_SAMPR_CAPS SAMPR_CAP_ALL |
13 | |||
14 | #define HW_SAMPR_CAPS (SAMPR_CAP_44) | ||
15 | 13 | ||
16 | /* define this if you have recording possibility */ | 14 | /* define this if you have recording possibility */ |
17 | #define HAVE_RECORDING | 15 | #define HAVE_RECORDING |
18 | 16 | ||
19 | #define REC_SAMPR_CAPS (SAMPR_CAP_22) | 17 | #define REC_SAMPR_CAPS SAMPR_CAP_ALL |
20 | #define REC_FREQ_DEFAULT REC_FREQ_22 /* Default is not 44.1kHz */ | ||
21 | #define REC_SAMPR_DEFAULT SAMPR_22 | ||
22 | |||
23 | #endif | ||
24 | 18 | ||
25 | /* Define bitmask of input sources - recordable bitmask can be defined | 19 | /* Define bitmask of input sources - recordable bitmask can be defined |
26 | explicitly if different */ | 20 | explicitly if different */ |
@@ -99,9 +93,9 @@ | |||
99 | /* There is no hardware tone control */ | 93 | /* There is no hardware tone control */ |
100 | #define HAVE_SW_TONE_CONTROLS | 94 | #define HAVE_SW_TONE_CONTROLS |
101 | 95 | ||
102 | /* We're working on the assumption that the AS3525 has something | 96 | /* AS3514 or newer */ |
103 | similar to the AS3514 for audio codec etc */ | ||
104 | #define HAVE_AS3514 | 97 | #define HAVE_AS3514 |
98 | #define HAVE_AS3543 | ||
105 | 99 | ||
106 | /* define this if you have a real-time clock */ | 100 | /* define this if you have a real-time clock */ |
107 | #ifndef BOOTLOADER | 101 | #ifndef BOOTLOADER |
diff --git a/firmware/export/config/sansafuzev2.h b/firmware/export/config/sansafuzev2.h index b42a0d1bb8..ddf42d9563 100644 --- a/firmware/export/config/sansafuzev2.h +++ b/firmware/export/config/sansafuzev2.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * This config file is for the Sandisk Sansa Fuze | 2 | * This config file is for the Sandisk Sansa Fuze v2 |
3 | */ | 3 | */ |
4 | #define TARGET_TREE /* this target is using the target tree system */ | 4 | #define TARGET_TREE /* this target is using the target tree system */ |
5 | 5 | ||
@@ -10,9 +10,9 @@ | |||
10 | #define HW_SAMPR_CAPS SAMPR_CAP_ALL | 10 | #define HW_SAMPR_CAPS SAMPR_CAP_ALL |
11 | 11 | ||
12 | /* define this if you have recording possibility */ | 12 | /* define this if you have recording possibility */ |
13 | //#define HAVE_RECORDING | 13 | #define HAVE_RECORDING |
14 | 14 | ||
15 | //#define REC_SAMPR_CAPS SAMPR_CAP_ALL | 15 | #define REC_SAMPR_CAPS SAMPR_CAP_ALL |
16 | 16 | ||
17 | /* Default recording levels */ | 17 | /* Default recording levels */ |
18 | #define DEFAULT_REC_MIC_GAIN 23 | 18 | #define DEFAULT_REC_MIC_GAIN 23 |
@@ -89,9 +89,9 @@ | |||
89 | #define LCD_PIXELFORMAT RGB565 /* rgb565 */ | 89 | #define LCD_PIXELFORMAT RGB565 /* rgb565 */ |
90 | 90 | ||
91 | 91 | ||
92 | /* We're working on the assumption that the AS3525 has something | 92 | /* AS3514 or newer */ |
93 | similar to the AS3514 for audio codec etc */ | ||
94 | #define HAVE_AS3514 | 93 | #define HAVE_AS3514 |
94 | #define HAVE_AS3543 | ||
95 | 95 | ||
96 | /* Define this if you have a software controlled poweroff */ | 96 | /* Define this if you have a software controlled poweroff */ |
97 | #define HAVE_SW_POWEROFF | 97 | #define HAVE_SW_POWEROFF |