diff options
| author | Linus Nielsen Feltzing <linus@haxx.se> | 2003-07-22 18:34:23 +0000 |
|---|---|---|
| committer | Linus Nielsen Feltzing <linus@haxx.se> | 2003-07-22 18:34:23 +0000 |
| commit | 4bb3f80f2737ff86c4a8fdb074a1a7bce0aa3624 (patch) | |
| tree | 83b7ef70d19188765012ac5ba648a85c32f17637 /firmware | |
| parent | cad92039846dfe6da48b385c350f3456bb990527 (diff) | |
| download | rockbox-4bb3f80f2737ff86c4a8fdb074a1a7bce0aa3624.zip rockbox-4bb3f80f2737ff86c4a8fdb074a1a7bce0aa3624.tar.gz rockbox-4bb3f80f2737ff86c4a8fdb074a1a7bce0aa3624.tar.bz2 rockbox-4bb3f80f2737ff86c4a8fdb074a1a7bce0aa3624.tar.xz | |
Setting the lowest mic gain no longer turns off the mic (bug #774349)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3865 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
| -rw-r--r-- | firmware/export/mpeg.h | 2 | ||||
| -rw-r--r-- | firmware/mpeg.c | 9 |
2 files changed, 6 insertions, 5 deletions
diff --git a/firmware/export/mpeg.h b/firmware/export/mpeg.h index dda93f8..9f266bf 100644 --- a/firmware/export/mpeg.h +++ b/firmware/export/mpeg.h @@ -89,7 +89,7 @@ void mpeg_record(char *filename); void mpeg_set_recording_options(int frequency, int quality, int source, int channel_mode, bool editable); -void mpeg_set_recording_gain(int left, int right, int mic); +void mpeg_set_recording_gain(int left, int right, bool use_mic); unsigned long mpeg_recorded_time(void); unsigned long mpeg_num_recorded_bytes(void); #endif diff --git a/firmware/mpeg.c b/firmware/mpeg.c index 2277615..b59c058 100644 --- a/firmware/mpeg.c +++ b/firmware/mpeg.c @@ -2142,7 +2142,7 @@ static void init_recording(void) mas_writereg(0xa3, 0x90); } - /* Enable the Left A/D Converter */ + /* Enable A/D Converters */ mas_codec_writereg(0x0, 0xcccd); /* Copy left channel to right (mono mode) */ @@ -2925,14 +2925,15 @@ void mpeg_set_recording_options(int frequency, int quality, } } -void mpeg_set_recording_gain(int left, int right, int mic) +/* If use_mic is true, the left gain is used */ +void mpeg_set_recording_gain(int left, int right, bool use_mic) { /* Enable both left and right A/D */ mas_codec_writereg(0x0, (left << 12) | (right << 8) | - (mic << 4) | - (mic?0x0008:0) | /* Connect left A/D to mic */ + (left << 4) | + (use_mic?0x0008:0) | /* Connect left A/D to mic */ 0x0007); } |