logo_jazz jp


monemurV3

tutos_monemurV201




This Lemur template acts as a Monome 40h, 128 or 256. In many cases, you can use the template directly with your Monome application, without anything extra. In some other cases, it can be handy or necesssary to use the included Max5 patch. You never need MonomeSerial to use Monemur.

After you familiarize yourself with the port, IP and prefix settings, you can use Monemur alongside a real monome, each talking to their own app. If you want to get fancy, you could also have multiple Monemur copies running on your Lemur, each on its own interface page. For now, first things first.

monemur_max


In a sense, this is the easiest way to use Monemur because it uses the Monome default ports (8000/8080) and prefix (/256). On the other hand, it can quickly get confusing with the ports and IPs. I recommend reading the next section and learning how to change the prefix in your applications, or alternatively in the Lemur template.


  • Load monemur_v3.jzml

  • Load monemur_v3.maxpat (It doesn’t mean you need to own a copy of Max/MSP. You can simply run it with Max 5 Runtime, which is available for free from .)

  • Set your Lemur OSC Target 0 to your computer’s IP or 255.255.255.255.

  • Set your Lemur OSC Target 0 to port 7999.

  • Enter your Lemur’s IP in the Max patch.

  • Set the prefix in the Max patch or click Respond to /sys/prefix messages.


As far as most Monome apps are concerned (you’ll find a list of Monome applications on the website), there is now a Monome 256 listening and transmitting on the default Monome ports. This means your Monemur will transmit to port 8000 (the default Monome app transmitting port) and listen to port 8080 (the default Monome app hosting port). Notice that port 8000 is also the default Lemur transmitting port, hence a possible source of confusion. In this case we set the Lemur OSC Target 0 to 7999 simply to avoid confusion. You CAN have two apps/machines listening to the same port, as long as they are not on the same IP. Since your Lemur and your computer have distinct IP’s, you could have both listening to port 8000. Let’s stick to 7999 for the sake of clarity.

monemur_nomax


puce Setting the application prefix

The default prefix for Monemur is /monemur. This is hardcoded in the Lemur template.

The best and easiest situation is when you can easily set your application to use a custom prefix. 7up, for example, easily allows you to specify which prefix to use, as well as which ports to transmit and listen to. Since the Lemur can only listen on port 8000, that should be the application transmit port. The listen port can be anything you want, as long as it’s the same thing you set in OSC Target 0.

Other applications are either hardcoded to use a certain prefix, or it can be changed with some effort. If it’s hardcoded, use the Max patch. If it can be changed, I recommend changing it to /monemur and using the template natively. With mlr, for example, you would have to unlock the max patch, find the 40h osc subpatch, and edit the message prepends. Depending on the application this can be more or less work but is certainly worth the effort because once it’s done, you can use Monemur and your app without the Max5 patch open.

If you don’t want to go to that trouble, simple leave Monemur in its default settings and fire up the Max5 patch.

puce Changing Monemur’s prefix

Another way of getting Monemur to talk to your app is changing the /monemur prefix in the Lemur template.

Edit the five following scripts to reflect the desired prefix:

  • /functions/clear(OSC_ARGS) — edit the Custom Address

  • /functions/led(OSC_ARGS) — edit the Custom Address

  • /functions/led_col(OSC_ARGS) — edit the Custom Address

  • /functions/led_row(OSC__ARGS) — edit the Custom Address

  • /functions/press() — edit the “oscout(osc_out, ‘/monemur/press’, out);” line


This can be useful to know when you want to integrate Monemur as one interface page in a more complex performance patch, or if you want to use a real Monome simultaneously.

puce Molar

Even though Molar permits you to specify prefix, transmit (hosting) and listening port, it still seems necessary to use the Max patch with the default Monome ports. It seems that Molar will only listen to messages sent from localhost (127.0.0.1). So, even though Monemur is sending the right message to the right port, Molar doesn’t recognize it until the message has been relayed by the Max patch (and thus coming form localhost. I can’t say for sure if this is the problem, but Molar certainly interacts very well with Monemur through the Monemur Max patch.

  • Load monemur_v3.jzml

  • Load monemur_v3.maxpat

  • Set your Lemur OSC Target 0 to 255.255.255.255 *or* your computer’s IP.

  • Set your Lemur OSC Target 0 to port 7999.

  • Enter your Lemur’s IP in the Max patch.

  • Set the prefix in the Max to /256

  • In Molar.CFG, use the default settings:

  • [256] the prefix, must be 3 chars exactly!

  • [8000] port that MonoChrome listens to.

  • [8080] port that MonoChrome hosts.

  • [127] remote ip address (127)

  • [0] ip address, (0)

  • [0] ip address (0)

  • [1] ip address (1)


puce Monome OSC protocol

Monemur transmits the following message:
  • /monemur/press

and listens for these messages:
  • /monemur/led

  • /monemur/led_col

  • /monemur/led_row

  • /monemur/clear


Please see the monome docs for more information about the monome osc protocol:

/sys/prefix messages only work if you use the included Max5 patch. This is due to a limitation of the Lemur scripting language, which does not (yet) provide functions for parsing strings.


puce Credits


  • Nick Bugayev –

  • Chris Lloyd

Download this example
Download JazzEditor from Support Section
Go back to workshops


© Copyright JazzMutant 2016 12-25-2016
Bitnami