asking (what track am I on?) from a MFL device

Shane's icon

Hey, this should be easy. I want to make a MFL device dropped on a channel query what channel it's on. The purpose is to then send that to a hub prepended to other info so the hub knows which channel device it's getting the info from.

If it's just a few objects a patch would be greatly appreciated as well. All I need is the way to ask "where am I?" not the other stuff.
Thanks

Shane

Ben Bracken's icon
Max Patch
Copy patch and select New From Clipboard in Max.

check out the 'this_device' in the Live Object Model. You can then do a 'getpath' on the resulting id. I use something like the following abstraction:

Shane's icon

Awesome thanks, just what I needed. Things don't really get this low level on the maxforlive.com site but this is a useful little abstraction.

broc's icon

Ben,

regarding your patch I'm wondering if there is an advantage using a path message with loadbang instead of an object [live.path this_device] which is initialized automatically when loaded?

Ben Bracken's icon

Either method should work fine. The loadbang is just habit on my part.

-Ben

Les Stuck's icon

Nice patch, Ben!

Here's my bizarre device that allows you to control track volume, panning, and sends.

Since it essentially duplicates the functionality of Live itself,
it's not meant to be a device that you just plug in and use.
Instead, you can copy parts of it if you want your device to control the track's mixer.

For example, it you want multichannel audio output controlled by the MFL device,
you can control the track's sends for that purpose.

xo<

Max Patch
Copy patch and select New From Clipboard in Max.