[Stk] crtsine.cpp gives RtApiAlsa: error starting callback thread!

Gary P. Scavone gary@ccrma.Stanford.EDU
Thu, 9 Feb 2006 21:54:15 -0500


Hi Charlls,

It is odd that you are getting an ALSA error report if you did not  
provide the -D__LINUX_ALSA__ preprocessor definition during  
compilation.  My guess wrt to the error below is the same issue I  
reported yesterday ... please see the archives.  To repeat:

In RtAudio, search for "pthread_attr_setschedpolicy(&attr,  
SCHED_RR);" and change the SCHED_RR to SCHED_OTHER.  Make sure you  
are in the RtApiAlsa section of the code.

I don't know why this is a problem for some and not others but I will  
likely make this change in the next release of RtAudio.

Also, you shouldn't get this error if you are using the Jack API.   
And RtAudio should use the Jack API automatically if it is only  
compiled with Jack support.  In fact, even if there is multiple Linux  
audio API support compiled in, Jack gets highest priority.  So, if  
RtAudio finds a running Jack server when it starts up, it uses that.

Regards,

--gary

On 9-Feb-06, at 9:45 PM, Charlls Quarra wrote:

>
> Hi,
>
> compiling the following example:
> http://ccrma.stanford.edu/software/stk/crealtime.html
>
> with
> g++ -D__LINUX_JACK__ crtsine.cpp -o crtsine -lpthread -ljack - 
> lasound -lstk
>
> ah, btw, i created an ebuild script for stk-4.2.1 for gentooers, is  
> in the revision step but can be fetched at:
> http://bugs.gentoo.org/show_bug.cgi?id=122321 (see attachment)
>
> when i run crtsine i get this error,
>
> RtApiAlsa: error starting callback thread!
>
> this error occurs at
> dac->setStreamCallback(&tick, (void *)&sine);
>
> any ideas what i'm doing wrong? jackd is running fine while i run  
> the program
>
>
>
> 1GB gratis, Antivirus y Antispam
> Correo Yahoo!, el mejor correo web del mundo
> Abrí tu cuenta aquí