summaryrefslogtreecommitdiffstats
path: root/firmware/target
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target')
-rw-r--r--firmware/target/coldfire/mpio/audio-mpio.c7
-rw-r--r--firmware/target/coldfire/pcm-coldfire.c13
2 files changed, 13 insertions, 7 deletions
diff --git a/firmware/target/coldfire/mpio/audio-mpio.c b/firmware/target/coldfire/mpio/audio-mpio.c
index 217881547e..88c43383ca 100644
--- a/firmware/target/coldfire/mpio/audio-mpio.c
+++ b/firmware/target/coldfire/mpio/audio-mpio.c
@@ -46,6 +46,7 @@ void audio_set_output_source(int source)
if ((unsigned)source >= AUDIO_NUM_SOURCES)
source = AUDIO_SRC_PLAYBACK;
+ /* route incoming audio samples to DAC */
IIS2CONFIG = (IIS2CONFIG & ~(7 << 8)) | (txsrc_select[source+1] << 8);
restore_irq(level);
@@ -73,8 +74,8 @@ void audio_input_mux(int source, unsigned flags)
break;
case AUDIO_SRC_MIC:
- case AUDIO_SRC_LINEIN:
- /* recording only */
+ case AUDIO_SRC_LINEIN:
+ /* recording only */
if (source != last_source)
{
audiohw_set_recsrc(source,true);
@@ -89,10 +90,10 @@ void audio_input_mux(int source, unsigned flags)
last_recording = recording;
+ audiohw_set_recsrc(source,recording);
/* Int. when 6 samples in FIFO, PDIR2 src = iis1RcvData */
coldfire_set_dataincontrol(recording ?
((3 << 14) | (4 << 3)) : 0);
- audiohw_set_recsrc(source, recording);
break;
}
diff --git a/firmware/target/coldfire/pcm-coldfire.c b/firmware/target/coldfire/pcm-coldfire.c
index 06f17d1170..fa320dff3f 100644
--- a/firmware/target/coldfire/pcm-coldfire.c
+++ b/firmware/target/coldfire/pcm-coldfire.c
@@ -84,13 +84,18 @@ static const unsigned char pcm_freq_parms[HW_NUM_FREQ][2] =
#endif
#if CONFIG_CPU == MCF5249 && defined(HAVE_WM8750)
+/* We run codec in master mode.
+ * Codec can reconstruct all frequencies
+ * from single 11.2896 MHz master clock
+ */
static const unsigned char pcm_freq_parms[HW_NUM_FREQ][2] =
{
- [HW_FREQ_88] = { 0x0c, 0x01 },
- [HW_FREQ_44] = { 0x06, 0x01 },
- [HW_FREQ_22] = { 0x04, 0x01 },
- [HW_FREQ_11] = { 0x02, 0x01 },
+ [HW_FREQ_88] = { 0x00, 0x01 },
+ [HW_FREQ_44] = { 0x00, 0x01 },
+ [HW_FREQ_22] = { 0x00, 0x01 },
+ [HW_FREQ_11] = { 0x00, 0x01 },
};
+
#endif
#if (CONFIG_CPU == MCF5250 || CONFIG_CPU == MCF5249) && defined(HAVE_TLV320)