From 722ab32d259bad3b0cdbbd67a025ed9f1d0c80c6 Mon Sep 17 00:00:00 2001 From: Libin Yang Date: Tue, 16 Apr 2019 15:20:55 +0800 Subject: [PATCH] topology: sof: add pipe-passthrough-capture_16k.m4 DMIC16k only supports 16000Hz sample rate. pipe-passthough-capture.m4 only supports 48000Hz. Add pipe-passthrough-capture_16k.m4 to support 16KHz record. Signed-off-by: Libin Yang --- .../sof/pipe-passthrough-capture_16k.m4 | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 tools/topology/sof/pipe-passthrough-capture_16k.m4 diff --git a/tools/topology/sof/pipe-passthrough-capture_16k.m4 b/tools/topology/sof/pipe-passthrough-capture_16k.m4 new file mode 100644 index 000000000000..f711caf85c14 --- /dev/null +++ b/tools/topology/sof/pipe-passthrough-capture_16k.m4 @@ -0,0 +1,50 @@ +# Capture Passthrough Pipeline and PCM for 16KHz +# This is a temporary solution. After FW supports the +# refinement of sample rate, this file will be removed +# and the default Passthrough will support all kinds +# of sample rates. +# +# Pipeline Endpoints for connection are :- +# +# host PCM_C <-- B0 <-- sink DAI0 + +# Include topology builder +include(`utils.m4') +include(`buffer.m4') +include(`pcm.m4') +include(`dai.m4') +include(`pipeline.m4') + +# +# Components and Buffers +# + +# Host "Passthrough Capture" PCM +# with 0 sink and 2 source periods +W_PCM_CAPTURE(PCM_ID, Passthrough Capture, 0, 2) + +# Capture Buffers +W_BUFFER(0, COMP_BUFFER_SIZE(2, + COMP_SAMPLE_SIZE(PIPELINE_FORMAT), PIPELINE_CHANNELS, SCHEDULE_FRAMES), + PLATFORM_PASS_MEM_CAP) + +# +# Pipeline Graph +# +# host PCM_C <-- B0 <-- sink DAI0 + +P_GRAPH(pipe-pass-capture-PIPELINE_ID, PIPELINE_ID, + LIST(` ', + `dapm(N_PCMC(PCM_ID), N_BUFFER(0))')) + +# +# Pipeline Source and Sinks +# +indir(`define', concat(`PIPELINE_SINK_', PIPELINE_ID), N_BUFFER(0)) +indir(`define', concat(`PIPELINE_PCM_', PIPELINE_ID), Passthrough Capture PCM_ID) + +# +# PCM Configuration +# + +PCM_CAPABILITIES(Passthrough Capture PCM_ID, COMP_FORMAT_NAME(PIPELINE_FORMAT), 16000, 16000, PIPELINE_CHANNELS, PIPELINE_CHANNELS, 2, 16, 192, 16384, 65536, 65536)