Penguin
Note: You are viewing an old revision of this page. View the current version.

Software playback of MIDI files

TiMidity++ is a software synthesizer that reads MIDI files and computes regular sample data that can be played back with any soundcard just like an MP3 or Ogg. Most distributions include it as a Package called timidity.

Playing MIDI files on a SBLive! sound card

To play MIDI files, load "sound fonts" into the sound card's memory, and then use those to play MIDI files. Sound fonts are collections of samples for the MIDI sequencer wave table; the CDROM that came with your soundcard has some.

Your ALSA drivers must have been built with the --with-sequencer=yes configure option, and you need the sfxload program. It is designed for the SB AWE32 and AEW64, but works with SBLive cards too. (In Debian it’s available as the awesfx Package.)

You can load a sound font by issuing something like sfxload 8mbgmsfx.sf2. You can check that it is loaded into the soundcard's memory by doing cat /proc/asound/card0/wavetableD1:

Device: Emu10k1
Ports: 4
Addresses: 65:0 65:1 65:2 65:3
Use Counter: 0
Max Voices: 64
Allocated Voices: 0
Memory Size: 134217728
Memory Available: 126786844
Allocated Blocks: 527
SoundFonts: 1
Instruments: 1849
Samples: 526
Locked Instruments: 1849
Locked Samples: 526

Then play a file using the playmidi program using the -a option to tell it to be AWE-compatible: playmidi -a dukenukem.mid

Make sure the volume for the sequencer isn't muted; in alsamixer, you are looking for the slider named "Music".


Part of CategoryNotes