Re: [LAU] midi capture of external hardware over usb

From: Gabriel M. Beddingfield <gabriel@email-addr-hidden>
Date: Sat Dec 19 2009 - 22:51:39 EET

On Sat, 19 Dec 2009, robert lazarski wrote:
> The Oasys sequence is playing at 78 bpm, but this didn't help:
>
> arecordmidi --port 24:0 --bpm=78 oasys.mid &
>
> Any other ideas?

Yes....

1. It *was* simple to do.
2. It *was* phun.

Download this, and make sure you have the libjack-dev and
g++ installed:

http://www.teuton.org/~gabriel/code/midixlate-0.1.0.tar
http://www.teuton.org/~gabriel/code/midixlate-0.1.0.tar.bz2.sha1

To set up your mapping, go to line 232 of main.cpp and set
up your mapping. Here's what it looks like:

void MidiTranslate::init_note_map()
{
     /* Here, add your midi mappings. If you don't
      * map a note here, then the note will not be translated
      * but pass through unchanged.
      *
      * Syntax:
      *
      * _note_map[orig] = xlate;
      *
      * Where 'orig' is the value of the "Original" note, and
      * 'xlate' is the value of the translated note.
      */
     _note_map[36] = 40;
     _note_map[37] = 36;
     _note_map[38] = 41;
     _note_map[39] = 37;
}

Add and change lines as you see fit. These are all decimal
note numbers. When you're done, save the file and issue the
'make' command.

To run it, make sure you start jackd with the -Xseq option
to create the bridge between ALSA MIDI and JACK MIDI. Then,
run this program. Use something lack qjackctl to insert it
between your input and output ports on the 2x2.

Hope it helps!!

-gabriel
_______________________________________________
Linux-audio-user mailing list
Linux-audio-user@email-addr-hidden
http://lists.linuxaudio.org/mailman/listinfo/linux-audio-user
Received on Sun Dec 20 00:15:03 2009

This archive was generated by hypermail 2.1.8 : Sun Dec 20 2009 - 00:15:03 EET