vendredi 14 août 2020

How do you duplicate an alsa audio stream?

I have only one device as listed below (p.s. The second one is only a dummy) -

# aplay -l

**** List of PLAYBACK Hardware Devices ****

card 0: tlv320aic32x4 [tlv320aic32x4], device 0: tlv320aic32x4-hifi tlv320aic32x4-hifi-0 [] Subdevices: 1/1 Subdevice #0: subdevice #0

card 0: tlv320aic32x4 [tlv320aic32x4], device 1: e001d000.i2s-dummy-codec-1 [] Subdevices: 1/1 Subdevice #0: subdevice #0

I already have an application that uses this device for streaming audio (so any audio input coming to the microphone is streamed out). Now i have to add another application that also uses the same microphone of this audio device. So this is resulting in a contention for the audio device. How can i avoid this contention ?

I have seen an another post in stack overflow where it talks about "type multi" alsa module to play sound to two different devices". But my problem is different. I do not have two different devices. I only have that one device.

Is it possible to duplicate an audio stream in alsa ? so that this sort of contention can be avoided and various applications can continue to use the audio information from a single audio device.

Aucun commentaire:

Enregistrer un commentaire