Midi router: mididings

De Wikijoan
Dreceres ràpides: navegació, cerca

mididings is a MIDI router and processor, supporting ALSA and JACK MIDI. It is available under the GNU GPL and currently runs on Linux.




   * Python ≥ 2.5
   * Boost ≥ 1.34.1 (Boost.Python, Boost.Thread)
   * ALSA
   * JACK

Necessito boost, que no sé el que és.

Per instal.lar boost: http://ubuntuforums.org/showthread.php?t=978487

Vaig a www.boost.org (Boost C++ Libraries)(Boost provides free peer-reviewed portable C++ source libraries.) i em baixo la última versió (1.42.0, febrer 2010): boost_1_42_0.tar.gz. són 39 MB.

$ tar xzf boost_1_42_0.tar.gz
$ cd boost_1_42_0

Mirar Getting Started: http://www.boost.org/doc/libs/1_42_0/more/getting_started/unix-variants.html

$ ./bootstrap.sh -> ha funcionat
$ ./bjam -> compila bé.
$ sudo ./bjam install

The only error messages you see when building Boost—if any—should be related to the IOStreams library's support of zip and bzip2 formats as described here. Install the relevant development packages for libz and libbz2 if you need those features. Other errors when building Boost libraries are cause for concern. -> són els errors que jo trobo, per tant no els dono importància

Ja puc tornar a la instal.lació del mididings.

./setup.py build
sudo ./setup.py install

i s'ha instal.lat bé!

Exemple 1

Les becerol.les: Exemple 1

Let's start with something very simple. fitxer transpose.py:

from mididings import *


The import statement imports everything from the mididings Python module into the global namespace. The run() function is then used to run a simple patch, in this case consisting of just a single Transpose() unit.

You can start this script by saving it to a Python file and executing it, for example:

$ python transpose.py

What this script does is to create an ALSA MIDI client with one input and one output port. It will then start listening for events on the input port, transpose all incoming note-on and note-off events up by 3 semitones, and send all events to the output port. Pressing Ctrl+C terminates the script.

Això és lo important. Tenim un client ALSA MIDI, i connecto el vkeybd al client transpose, i el client transpose al fluidsynth, i ja tinc el primer exemple de midi router amb mididings: una transposició de 3 semitons.

Però no funciona...

$ python transpose.py
Traceback (most recent call last):
  File "transpose.py", line 1, in <module>
    from mididings import *
  File "/usr/local/lib/python2.6/dist-packages/mididings/__init__.py", line 14, in <module>
    from mididings.engine import run, run_scenes, run_patches, process_file
  File "/usr/local/lib/python2.6/dist-packages/mididings/engine.py", line 13, in <module>
    import _mididings
ImportError: libboost_python.so.1.42.0: cannot open shared object file: No such file or directory

$ cd /usr/local/lib
$ ls -la
lrwxrwxrwx  1 root root       25 2010-02-16 01:12 libboost_python.so -> libboost_python.so.1.42.0

de moment, no surt

creat per Joan Quintana Compte, febrer 2010

Eines de l'usuari
Espais de noms
Institut Jaume Balmes
Màquines recreatives
Informàtica musical
joanillo.org Planet