Page 1 of 1

Linuxsampler without a frontend

Posted: Fri Feb 18, 2011 5:31 pm
by Cerapter
In order to save time, resources and desktop space, I decided to make an audio session script and run linuxsampler from the command line.

I got the LSCP script from Fantasia, and it works fine. But I'm a little fuzzy about how Linuxsampler really runs on my system, and perhaps most importantly, how do I stop it? (Do I need to?)

Here's how I run it from a bash script currently:

Code: Select all

linuxsampler &
cat ~/jsampler_jack.lscp | netcat localhost 8888 &

Re: Linuxsampler without a frontend

Posted: Sat Feb 19, 2011 12:56 am
by Cerapter
For the above script to work properly, I had to enter a few seconds of sleep:

Code: Select all

linuxsampler &
sleep 5
cat ~/jsampler_jack.lscp | netcat localhost 8888 &
To shut it down, I simply kill it with another script when I'm done:

Code: Select all

killall -w linuxsampler
I'm saving a lot of time setting up Fantasia just once to make an lscp script, and then sending this directly to linuxsampler the next time around. :D

Re: Linuxsampler without a frontend

Posted: Sat Feb 19, 2011 10:49 pm
by Alex
At OpenOctaveProject, running Ls from the terminal is more or less default behaviour. Once a frontend like fantasia has been used to build our large orchestral templates, then the cat command is run from inside a script, which starts not only LS, but jack, and oomidi as well.

Good to see someone else getting good CPU and RAM resource value out of LS's backend/frontend design, and not afraid to use a terminal as well. :)

Yes, adding a sleep value is good, and if you decide to run another app from your script after the cat command has been issued, you should add some sleep there too, to the equivalent of how long it takes to load your .lscp template. (plus a second or 2)

Alex.