machine driver and channel configuration
Hi,
If the platform/cpu_dai driver and codec support capture and playback channels. But on the board only the playback link is connected.
In this configuration, the codec and platform/cpu_dai driver shouldn't try to use the capture path (and the resource associated to this).
Is there a way to do something like that ?
Thanks
Matthieu
Quoted 10 lines · Matthieu CASTET
Hi,
If the platform/cpu_dai driver and codec support capture and playback channels. But on the board only the playback link is connected.
In this configuration, the codec and platform/cpu_dai driver shouldn't try to use the capture path (and the resource associated to this).
Is there a way to do something like that ?
I'm just learning about ASoC myself, but using wm8731.c as an example, wouldn't this work:
struct snd_soc_codec_dai wm8731_dai = {
.name = "WM8731",
.playback = {
.stream_name = "Playback",
.channels_min = 1,
.channels_max = 2,
.rates = WM8731_RATES,
.formats = WM8731_FORMATS,},
.capture = {
.stream_name = "Capture",
.channels_min = 1,
.channels_max = 2,
.rates = WM8731_RATES,
.formats = WM8731_FORMATS,},Just change capture.channels_min and channels_max to 0.
Signature · 2 lines
Timur Tabi Linux Kernel Developer @ Freescale
Hi,
Quoted 32 lines · Timur Tabi
Quoted 6 lines · Matthieu CASTET
Hi,
If the platform/cpu_dai driver and codec support capture and playback channels.
But on the board only the playback link is connected.Quoted 6 lines
In this configuration, the codec and platform/cpu_dai driver shouldn't try to
use the capture path (and the resource associated to this).Is there a way to do something like that ?
I'm just learning about ASoC myself, but using
wm8731.cas an example, wouldn't this work:struct snd_soc_codec_dai wm8731_dai = { .name = "WM8731", .playback = { .stream_name = "Playback", .channels_min = 1, .channels_max = 2, .rates = WM8731_RATES, .formats = WM8731_FORMATS,}, .capture = { .stream_name = "Capture", .channels_min = 1, .channels_max = 2, .rates = WM8731_RATES, .formats = WM8731_FORMATS,},
Quoted 2 lines
Just change capture.channels_min and
channels_maxto 0.
Hum, yes I could change channel info at runtime before doing the platform_device_add in machine driver.
I'll try that.
Thanks.
Matthieu
I think you can have multiple dai objects, in your dai object dont enable support for Capture, and use that dai object in your Machine driver.
This should solve the issue
Quoted 50 lines · Matthieu CASTET
Hi,
Quoted 32 lines · Timur Tabi
Quoted 6 lines · Matthieu CASTET
Hi,
If the platform/cpu_dai driver and codec support capture and playback channels.
But on the board only the playback link is connected.Quoted 6 lines
In this configuration, the codec and platform/cpu_dai driver shouldn't try to
use the capture path (and the resource associated to this).Is there a way to do something like that ?
I'm just learning about ASoC myself, but using
wm8731.cas an example, wouldn't this work:struct snd_soc_codec_dai wm8731_dai = { .name = "WM8731", .playback = { .stream_name = "Playback", .channels_min = 1, .channels_max = 2, .rates = WM8731_RATES, .formats = WM8731_FORMATS,}, .capture = { .stream_name = "Capture", .channels_min = 1, .channels_max = 2, .rates = WM8731_RATES, .formats = WM8731_FORMATS,},Quoted 2 lines
Just change capture.channels_min and
channels_maxto 0.Hum, yes I could change channel info at runtime before doing the
platform_device_addin machine driver.I'll try that.
Thanks.
Matthieu
_______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel