Multiples live_audio

Hello, I have an 8-channel sound card called umc404hd_192k.

And when I try to do this:

live_audio: umc404hd_192k, stereo: true, input: 1
live_audio: umc404hd_192k, stereo: true, input: 2

Channel 2 is disabled, only one channel works at a time in sonic pi.

Any idea?

Taking into account if I use live_audio: foo is going to capture my notebook’s microphone, I need to inform you that umc404hd_192k, is my sound card, correct?

How does it work?

Hi @carloseduardo :slight_smile: Have you checked the documentation in the Lang section of the help in the app for live_audio?

Yes, I read,

but what I didn’t understand is, do I need to specify the name of my sound card?

If so, why is one entry stopping the other entry?

Sorry for the question,

Sure, no problem.

No. As far as I understand it, Sonic Pi receive input from the default sound card that is active when it starts up.

So, one key thing to keep in mind is that as the documentation says:

only one live_audio synth of a given name may exist in the system at any one time

and also, what else may be helpful is looking at example 3 there:


When you specify stereo: true, the two channels are set to whatever is set for input, plus the next channel along. So in that example, audio is played from inputs 3 and 4.

Is that any clearer? :slight_smile:

1 Like

I’m not sure about Windows or Mac, but on Linux Sonic Pi will only use a single sound card at a time - you have to make sure it starts up using the correct one. So I’d suggest you look into how to make Sonic Pi use your 8-port card on your operating system.

If you tell us what your operating system is, someone might be able to tell you how to do that. But it’s probably documented, too.

‘umc404hd_192k’ is the variable name you gave that Captured input. You chose it yourself.

Then you create another ‘umc404hd_192k’, and by that you overwrote the first Captured inputs ‘name’. From then on, whenever you call for "‘umc404hd_192k’"m, you would get the second input. You cant call the first “‘umc404hd_192k’” again, because when you ask for the “‘umc404hd_192k’” you will get the second one.

Those two variables must have different names, so you can ‘find’ them again.

2 Likes