Cabbage Logo
Back to Cabbage Site

Like to use pulse on linux without glitches?

Try adding “–realtime” to the CsOptions section of your csd.

(yes I’m an idiot, but Rory didn’t know either)

I guess that makes us both idiots :laughing:

I’ll be honest, I have never seen that flag before, but it looks like it might have helped me in another project I was working on recently :see_no_evil:

Maybe some kind of checkbox in the cabbage settings that adds --realtime to the options used to run all csds?

Having audio file reading and writing happening in another thread can only be good.

I’ll try it on android too, I suspect apps on android aren’t able to set realtime privileges as without a bunch of hacking that goes on in real linux distros you need root access. I have an instrument that randomly jumbles and crossfades a directory full of sound files, it glitches like crazy on android, if the files were being read and uncompressed on a different core though (!)

There’s also


Linux only. Use real-time scheduling and lock memory. (Also requires -d and either -o dac or -o devaudio ). See also --sched=N below.


Linux only. Same as --sched, but allows specifying a priority value: if N is positive (in the range 1 to 99) the scheduling policy SCHED_RR will be used with a priority of N; otherwise, SCHED_OTHER is used with the nice level set to N. Can also be used in the format --sched=N,MAXCPU,TIME to enable the use of a “watchdog” thread that terminates Csound if the average CPU usage exceeds MAXCPU percents over a peroid of TIME seconds (new in Csound 5.00).

edit: unfortunately in the main csound for android app, csds using the --realtime option appear to just exit and don’t play. The csd I tested has no GUI, when I try running it on cabbage on android I just get a blank screen with no sound and no way to get back to the home screen. Curiously the same thing happens in csoundqt on my manjaro linux box- csds just exiting without sound, when I definitely have permission to switch to realtime scheduling.

edit2: in the main cabbage prog on linux the --realtime flag also suppresses most printing, to be used with care.

1 Like