help.OSC - tooll3/t3 GitHub Wiki

Sending and receiving OSC messages

Different end points

Sending network messages can be a complex topic, because there are many pitfalls like different protocols and firewall settings. Here we collect frequent questions on that topic:

ZigOSC (iOS app)

Hexler Protokol

Protokol is a very nice debugging and logging application available for various platforms. In Windows you might need to switch the protokol from IP6 to IP4: image

Bitwig

  1. Install the DrivenByMoss extension for your version of Bitwig.
  2. Follow the installation guide for "Open Sound Controllers" and create a new OSC controller on the Controllers page in Settings:

image

You should see the controller settings then (or open them with the gear icon):

image

  1. Set up the ports and IP address and the resolution for the values you need.

Important: The values for for instance volume faders are sent and expected as integers between 0 and the value you set in the "Value Resolution" dropdown, so 0-127 for Low, 0-1023 for Medium and 0-16383 for High.

SuperCollider and Tidal Cycles

TidalCycles is a music live coding environment using the haskel programming language and built on top of SuperCollider. It's incredibly powerful and expressive. The great thing about SC is that all internal communication is based on a client server architecture that uses OSC messages for communication.

This means that intercepting and forwarding these messages to T3 is already build in:

In super collider the only thing you have the execute is a block like this (adjust the 192.169.1.6 IP-Address to your needs).

(
var targetAddr = NetAddr("192.168.1.6", 8000);

s.waitForBoot {

    // Add a listener for incoming OSC messages
    OSCFunc({ |msg, time, addr|
        targetAddr.sendBundle(time, msg, addr);
    });
}
)

When now in Tidal you execute something like...

import Sound.

setcps 0.11

d1 $ n "[12 123 23 23 2]" # s "test2" 
d2 $ n "[1 2 3 4]" # s "test3" 

We can do the following steps in Tooll:

  1. Create an [OscInput] operator
  2. Enable the log-messages parameter

... we should receive OSC messages in Tooll that look like this:

/dirt/play, "id", "1", "cps", 0.5208333f, "cycle", 1588.8f, "delta", 0.384f, "n", 2f, "orbit", 0, "s", "test2"

Like many other applications, Super Collider encodes data into a list of key/value pairs. In the example message above, you might notice how every second attribute is a string ("id", "cps", "cycle", etc.). To make it more convenient to work with OSC messages in that format, you can enable [OscInput]'s UseKeyValuePairs parameter which will give you a result like this:

image

That's great because we can use the "cycles" attribute to drive the Tooll time via [SetCommandTime].