Eugenio Bargiacchi
2017-02-09 18:53:12 UTC
Hello,
Due to a program that can only work using mono devices, I need to convert
my microphone's device, which is stereo only, into a mono device.
The correct device can be seen from arecord as this:
$ arecord -L
.....
front:CARD=Generic,DEV=0
HD-Audio Generic, CS4207 Analog
Front speakers
.....
So I tried to create a new device into the /usr/share/alsa/alsa.conf file.
I've tried with this:
pcm.makemono {
type plug
slave.pcm {
type route
slave.pcm "pcm.front"
slave.channels 2
ttable {
0.0 1
1.0 1
}
}
}
Where I've found pcm.front some lines before in the file as
pcm.front cards.pcm.front
(I'm not sure that using "pcm.front" in my makemono device is correct)
However, calling arecord with this device and a single channel still gives
me problems. At the same time, calling arecord with any device names seems
not to create any type of complaint, so I'm wondering whether this new
`makemono` device has been correctly parsed and recognized by ALSA.
I'm currently trying to record the device with
$ arecord -f cd -d makemono -c 1 -V stereo /tmp/file
How can I check that this new device actually exists and does what I need?
Thanks in advance for any help.
Best,
Eugenio
Due to a program that can only work using mono devices, I need to convert
my microphone's device, which is stereo only, into a mono device.
The correct device can be seen from arecord as this:
$ arecord -L
.....
front:CARD=Generic,DEV=0
HD-Audio Generic, CS4207 Analog
Front speakers
.....
So I tried to create a new device into the /usr/share/alsa/alsa.conf file.
I've tried with this:
pcm.makemono {
type plug
slave.pcm {
type route
slave.pcm "pcm.front"
slave.channels 2
ttable {
0.0 1
1.0 1
}
}
}
Where I've found pcm.front some lines before in the file as
pcm.front cards.pcm.front
(I'm not sure that using "pcm.front" in my makemono device is correct)
However, calling arecord with this device and a single channel still gives
me problems. At the same time, calling arecord with any device names seems
not to create any type of complaint, so I'm wondering whether this new
`makemono` device has been correctly parsed and recognized by ALSA.
I'm currently trying to record the device with
$ arecord -f cd -d makemono -c 1 -V stereo /tmp/file
How can I check that this new device actually exists and does what I need?
Thanks in advance for any help.
Best,
Eugenio