How to Use Reaktor with Opusmodus

Written by on January 8, 2016 in LISP, Music, Programming with 0 Comments

For those of you who do not know about Opusmodus (OM), it is a very powerful and flexible algorithmic music composition environment built in Lisp. It is available for the Mac.

Today I wanted to understand how to make Opusmodus communicate with Reaktor 6 to play some tunes. The built-in documentation gives a couple of examples of how the interaction can be enabled, but I felt the explanation was too brief for a newbie. Nothing better than learning by experimenting!

Let us get started.

First you must configure the MIDI ports on the Mac. For this, launch the Audio MIDI Setup program located in the Utilities folder. Select Window>Show MIDI Studio from the menu. Then double-click on the IAC Driver icon in the MIDI studio. This will display the IAC Driver properties dialog.

IAC Driver

IAC Driver

Make sure you have at least Bus 1 in the list of MIDI ports available.

To see if the ports can be accessed from Opusmodus, execute the function (midi-destinations) in OM Listener. This will return a list of MIDI ports available for our use. See figure.

MIDI Destinations

MIDI Destinations

You can see that 4 ports have been set up on my Mac. Each port is shown with its number as well as name.

Next launch Reaktor. Since Reaktor is going to receive our MIDI messages, we need to ensure that the ports are set up correctly. Select File>Audio and MIDI Settings… from the menu, and switch to the MIDI tab. IAC Driver (Bus 1) must be turned on if it is off. For now we are not concerned with the other ports since we won’t be using them.

Reaktor MIDI Settings

Reaktor MIDI Settings

Next, we load the pre-installed synthesizer Green Matrix.ens. For this experiment, any synth will do since our objective is only to understand the interface between OM and Reaktor, and not to create professional music.

Loading a synthesizer

Loading a synthesizer

The next step is to configure the connection settings for this synthesizer. Click the EDIT button and then the Check mark at the top left to view the connection settings.

We are only interested in the first two parameters. Select IAC Driver (Bus 1) for External and use either 1 or Omni for the Channel parameter.

Connection settings for the synth

Connection settings for the synth

Now we are ready to program in OM. The following is a simple program fragment to test the communication.

Program-1

Program-1

The important point to note here is the use of :port option in the instrument section with a value of 0. You can also use the string name of the port if you wish. When you Evaluate and Play the program, you can hear the notes being played through Reaktor’s Green Matrix synth.

Let us now make it a bit more interesting. Opusmodus allows us to send control parameters, in addition to MIDI notes. Likewise, Reaktor allows us to manipulate device parameters through control codes. For this experiment, I decided to control the Pitch knobs of Oscillators 1, 2 and 3 by sending values from the program. To do that, we have to configure these UI controls such that each gets a unique control number and is enabled for MIDI input. See the screenshot (shows the settings for Oscillator 1).

Configure panel controls

Configure panel controls

I assigned CC Number 1 for Oscillator 1, 2 for Oscillator 2, and 3 for Oscillator 3. Then I modified the OM program to emit different control parameters as the notes are being emitted.

Program-2

Program-2

Notice the use of :controllers option with a list of various control codes and their values. As before, when you Evaluate and Play this program, you can see that the knobs on the panel keep changing their positions dynamically as notes are played through the synth! Exciting, isn’t it?

The few hours that I spent on this experiment was definitely worth it. I learnt a few things about Reaktor and OM that I did not know before.

Today’s post has been about using MIDI to communicate between programs, in particular between Opusmodus and Reaktor. In an earlier post I explained how you can control Reaktor using OSC. You may want to check that out too.

Tags: , ,

Subscribe

If you enjoyed this article, subscribe now to receive more just like it.

Subscribe via RSS Feed

Leave a Reply

Your email address will not be published. Required fields are marked *

Top