Outputting raw MIDI in realtime on Linux

N

Nick Irvine

I'm trying to output raw, realtime MIDI data (as in note on, note off,
etc) in Linux from Python, and I want the easiest way to do it. I've
been banging my head on the wall about this for quite some time. The
reason for this is to reinvent the old vkeybd application, but it's
just me screwing around, so not worth the time doing it in C or
creating a whole whack of supporting libraries.

What I have so far is vkeybd outputting to Qsynth (via an ALSA
VirMidi) to pulseaudio, playing some lovely grand piano. I want to
replace vkeybd with a Python program of my own design. Using Qsynth's
Messages window, I can monitor the rawish MIDI signals flowing.

According to http://www.tldp.org/HOWTO/MIDI-HOWTO-10.html , I should
be able to just dump MIDI bytes into /dev/snd/midiC3D0. However, this
yields nothing: Qsynth does not show receiving it. I even tried this
C example from the OSS docs, with the same result:

http://manuals.opensound.com/developer/midi.c.html

(I updated the /dev line.)

What do people use to output live MIDI on Linux, assuming it's
possible?

Thanks,
Nick Irvine
 
A

alex23

What do people use to output live MIDI on Linux, assuming it's
possible?

Hey Nick,

I've yet to try this myself although it's long been on my to-do list.

There are a couple of packages on PyPI that emit MIDI:
http://pypi.python.org/pypi?:action=search&term=midi

There is also an older project that provides a basic midi step
sequencer. I can't find a proper package or installer, but you might
find something useful in the 'midi_functions.py' file here:
http://www.akjmusic.com/software/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top