I've just finalized setting up ALSA MIDI + fluidsynth for Frescobaldi ... perhaps this setup script will be useful in the future.
DLT
#!/bin/sh
# dentonlt, 20120929
# set up and start music notation software
EXT="alsa
frescobaldi"
echo "${EXT}" |
while read FILE; do
echo "LOADING ${FILE} ..."
tce-load -i /tce/"${FILE}"
done
# set up kernel midi module
sudo modprobe snd_seq
# install fluidsynth
FSYNTH_SOUNDFONT="/home/tc/.local/bin/resources/pats/2MBGMGS/2MBGMGS.SF2"
fluidsynth -i -s -aalsa -o audio.alsa.device=default ${FSYNTH_SOUNDFONT} &
#alternatively, use qsynth instead of fluidsynth
# qsynth -a alsa &
sleep 2 # wait for fluidsynth to create ports
# connect standard through port (IN) to fluidsynth (OUT). This is probably not the easiest way, but it works.
THROUGH="`aconnect -i | grep "Midi Through" | cut -f 2 -d ' '`"
FLUID="`aconnect -o | grep "FLUID Synth" | cut -f 2 -d ' '`"
[ "${THROUGH}" ] && [ "${FLUID}" ] && aconnect ${THROUGH}0 ${FLUID}0
# start notation editor
frescobaldi