You are not logged in.
Pages: 1
Hi,
I've written myself a fluidsynth init script to start it up as a midi server like timidity++.
Anyone has a different soundfont just switch the filenames.
#!/bin/bash
. /etc/rc.conf
. /etc/rc.d/functions
case "$1" in
start)
stat_busy "Starting fluidsynth"
if [ -s /var/run/fluidsynth.pid ]; then
stat_fail
stat_busy "fluidsynth is already running."
stat_die
fi
/usr/bin/fluidsynth -s -i -a alsa "/usr/share/soundfonts/Titanic 200 GM-GS SoundFont 1.2.sf2" &>/dev/null&
echo "$!" > /var/run/fluidsynth.pid
stat_done
;;
stop)
stat_busy "Stopping fluidsynth"
kill `cat /var/run/fluidsynth.pid 2>/dev/null` &>/dev/null
if [ $? -ne 0 ]; then
stat_fail
else
rm /var/run/fluidsynth.pid
stat_done
fi
;;
restart)
$0 stop
sleep 1
$0 start
;;
*)
echo "usage: $0 {start|stop|restart}"
esac
Last edited by b4283 (2009-07-13 13:12:38)
Offline
Pages: 1