Bug found for dealing with multiple sound cards

58 views
Skip to first unread message

hendryx

unread,
Oct 16, 2010, 3:46:13 PM10/16/10
to emutrix
Hi cpolymeris,

I'm an owner of an E-MU 1616m and normally use it under Windows. I
played a bit with Ubuntu and managed to get my 1616m successfully
working - with the help of some forum entries on the net. I missed an
application similar to PatchMix DSP under Windows due to the lack of
Linux support from E-MU. But I found emutrix.

When I compiled it, it didn't recognize my E-MU card and stopped. So
that's why:

I have more than one soundcard, as there are (in list of recognized
order):

1. an internal sound card on the motherboard
2. the E-MU 1616m
3. a hybrid video capture card which is also listed here.

I investigated in your code and found the following situation:

file: soundcard.cc
line: 40

instead of this line here:
} while (snd_card_next(&i));
put this line there:
} while (!snd_card_next(&i) && i >=0 );

The logics of the return value of the snd_card_next() function is just
vice versa. The check for i being a positive value is just a quick and
dirty method because at the end of the sound card iteration I obtained
a negative value and the program failed, so I don't know if this is
really correct in this way.

My 1616m is now recognized and emutrix is working.

Regards
hendryx

Camilo Polymeris

unread,
Oct 17, 2010, 6:18:21 PM10/17/10
to emu...@googlegroups.com
On Sat, Oct 16, 2010 at 4:46 PM, hendryx <hend...@gmx.net> wrote:
> Hi cpolymeris,
Hello, Hendryx.

>
> I'm an owner of an E-MU 1616m and normally use it under Windows. I
> played a bit with Ubuntu and managed to get my 1616m successfully
> working - with the help of some forum entries on the net. I missed an
> application similar to PatchMix DSP under Windows due to the lack of
> Linux support from E-MU. But I found emutrix.

So, what do you think? emutrix is far from complete, and quite
different from PatchMix, of course. But, is it any help to you?
Eventualy, I'd like to add a lot more features, but don't have much
time. I assume you are an experienced Emu user: What features would
you like to see implemented?

>
> When I compiled it, it didn't recognize my E-MU card and stopped. So
> that's why:
>
> I have more than one soundcard, as there are (in list of recognized
> order):
>
> 1. an internal sound card on the motherboard
> 2. the E-MU 1616m
> 3. a hybrid video capture card which is also listed here.
>
> I investigated in your code and found the following situation:
>
> file: soundcard.cc
> line: 40
>
> instead of this line here:
>    } while (snd_card_next(&i));
> put this line there:
>    } while (!snd_card_next(&i) && i >=0 );
>
> The logics of the return value of the snd_card_next() function is just
> vice versa. The check for i being a positive value is just a quick and
> dirty method because at the end of the sound card iteration I obtained
> a negative value and the program failed, so I don't know if this is
> really correct in this way.
>

Ok. Thanks for bug spotting & correction. I added something similar to
the above to the code in svn. I'll now add a little more ALSA error
handling, I think.

> My 1616m is now recognized and emutrix is working.
>
> Regards
> hendryx

Thanks again,
Camilo

Reply all
Reply to author
Forward
0 new messages