« Playing with XFormer | Main | ddg says hello »
Monday
Dec212009

Clip grid remote control

Here's my remote controller for Live

 

You can grab the archive here. Please feel free to use it for non commercial purposes. Get in touch with us if you have any questions about usage.

 

PERFORM: remote control of Live sets over the network. from Andrew Pask on Vimeo.

 

 

Please let us know if you have any questions, feature requests, bug reports, you name it

 

 

PrintView Printer Friendly Version

EmailEmail Article to Friend

References (80)

References allow you to track sources for this article, as well as articles that were written in response to this article.
  • Response
    NFL is definitely one particular of the most significant sports in America. It has a important following.
  • Response
    I want to add a registration form to Joomla.. . I need to be able to edit the fields of the form. . The form needs to register people as users in Joomla, and trigger an HTML welcome email, as well as a notification to an admin about the registration.. . ...
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: official statement
    20Objects - Articles - Clip grid remote control
  • Response
    Response: Website
    20Objects - Articles - Clip grid remote control
  • Response
    Response: This Webpage
    20Objects - Articles - Clip grid remote control
  • Response
    Response: chiroractic
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: pinterest
    20Objects - Articles - Clip grid remote control
  • Response
    Response: bitly.com
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: vkontakte
    www.vkontakte.ru
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: iplaycraft.ru
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: singles dating
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: LED headlamp
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: used wedding dress
    20Objects - Articles - Clip grid remote control
  • Response
    Response: poker online
    20Objects - Articles - Clip grid remote control
  • Response
    Response: agen tangkasnet
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: agen judi online
    20Objects - Articles - Clip grid remote control
  • Response
    Response: agen bola
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    It�s a good shame you don�t contain a give money button! I�d definitely give money for this fantastic webpage! That i suppose for the time being i�ll be satisfied bookmarking together with including an individual�s Feed that will my best Msn balance. That i appearance forward that will recent messages and ...
  • Response
    Response: cerita sex dewasa
    20Objects - Articles - Clip grid remote control
  • Response
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: Cerita Sex 2016
  • Response
    Response: Cerita Sex Mesum
  • Response
    Response: Cerita Mesum HOT
  • Response
    Response: Cerita Sex Terbaru
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: https://Reddit.com
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote control
  • Response
    Response: halloween edm mix
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    Response: Judi Online
    20Objects - Articles - Clip grid remote
  • Response
    Response: houses For sale
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    Response: Get Source
    20Objects - Articles - Clip grid remote
  • Response
  • Response
    Response: kasino online
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    Response: Kasino online
    20Objects - Articles - Clip grid remote
  • Response
    Response: www.youtube.com
    20Objects - Articles - Clip grid remote
  • Response
    Response: bandarq
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    Response: Rental Mobil Jogja
    20Objects - Articles - Clip grid remote control
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    20Objects - Articles - Clip grid remote
  • Response
    Response: bandarq
    20Objects - Articles - Clip grid remote
  • Response
    Response: as pest control
    20Objects - Articles - Clip grid remote
  • Response
    Response: Edit HTML Online
    20Objects - Articles - Clip grid remote
  • Response
    Response: nonton gratis
    20Objects - Articles - Clip grid remote
  • Response
    Response: agen judi poker
    20Objects - Articles - Clip grid remote
  • Response
    Response: kontes seo judi
    20Objects - Articles - Clip grid remote

Reader Comments (9)

Andrew,

Cool stuff...

I did something similar, but i did not use javascript. I really think i am going to start using Javascript more often as it seems like the better way to go. I will probably design a front end on my Lemur to use instead of the remote. Good start though... Very useful for me.

Thanks,

Mike

December 27, 2009 | Unregistered CommenterMichael Chenetz

Cheers Mike!

December 29, 2009 | Registered CommenterAndrew

Very nice!

How about using Live´s GUI in the patch and allow multiple connections, so that many people could work on the same Live-set over network, using a Max-patch that looks like Live?

What about midi-devices connected to te remote computer being allowed to controll/play live?

Maybe also audio-override via network? maybe integrating something like http://code.google.com/p/wormhole2/ ?

This would be extremely usefull in bands where a lot of processor power is required, it would also make patching and syncing between musicians a lot easier.

Imagine having one powerfull computer with one sound card, which is controlled by all the band members.

Or assigning different parts of the Live set to different instances of the patch?

Please, keep up the good work!

Sincerely - Jonas Barsten Johnsen

January 4, 2010 | Unregistered CommenterJonas Barsten Johnsen

yeah!
thanks for this site
I just read the script about the grid.

my full m4L stuff is very fast and efficient.
I'd love to test the same with your script!
and I'll do asap

all the best
julien/protofuse

February 4, 2010 | Unregistered Commenterjulien
February 12, 2010 | Unregistered Commenterjulien

I really like this! I should learn some JS very soon, and by the looks of it, it's easy to read (but writing it is more challenging). Thank you very much for sharing!!!!

February 19, 2010 | Unregistered CommenterBouke Groenescheij

The last version I use:

/*
/////////////////////////////////////////////////////////////////////////////

Javascript Live API remote controller and Live set follower

20Objects LLC
20Objects.com
Written by
Andrew Pask andrew@20Objects.com
Darwin Grosse ddg@20Objects.com


Deeply tweaked for specific protodeck usage by
Julien Bayle julien.bayle@gmail.com

//////////////////////////////////////////////////////////////////////////////
*/

autowatch = 1;
outlets = 1;

const GRID_X_SIZE = 8;
const GRID_Y_SIZE = 6;

var scene = 0;
var num_scenes;
var num_tracks = 15;
var notePitch;

clip_slot_grid = new Array();
liveset_scenes = new Array();
clip_grid = new Array();
clip_play = new Array();


/////////////// Set up arrays and observe tracks and scenes in the Live set /////////////////
function set_up()
{

scene_observer = new LiveAPI(this.patcher, "live_set");
if (!scene_observer)
{
post("no api object","\n");
}

num_scenes = scene_observer.getcount("scenes");
for (y = 0; y < num_scenes; y++)
{
liveset_scenes[y] = new LiveAPI(this.patcher, "live_set scenes " + y);
if (!liveset_scenes[y])
{
post("no api object","\n");
}
}

for (x = 0; x < num_tracks; x++)
{
clip_grid[x] = new Array();
clip_slot_grid[x] = new Array();
clip_play[x] = new Array();
}

scanALL();
scene_observer.call("stop_all_clips");
}


function bang()
{
set_up();
}

//////////////// Create has_clip observers for each clip_slot fro the WHOLE live_set ////////////////
function scanALL()
{
for (x = 0; x < 15; x++)
{
for (y = 0; y < num_scenes ; y++)
{
if (!clip_slot_grid[x][y])
// don't need to create them if they already exist
{
clip_slot_grid[x][y] = new LiveAPI(this.patcher, device_callback, "live_set", "tracks", x, "clip_slots", y);
if (!clip_slot_grid[x][y])
{
post("no api object","\n");
}
clip_slot_grid[x][y].track = x;
clip_slot_grid[x][y].slot = y;
clip_slot_grid[x][y].property = "has_clip";

clip_play[x][y] = new LiveAPI(this.patcher, device_callback, "live_set", "tracks", x, "clip_slots", y, "clip");
if (!clip_play[x][y])
{
post("no api object","\n");
}
clip_play[x][y].track = x;
clip_play[x][y].slot = y;
clip_play[x][y].property = "playing_status";

// workaround for grabbing looped clip information
clip_play[x][y].call("fire");
clip_play[x][y].loop_status = clip_play[x][y].get("looping");
clip_play[x][y].call("stop");

}
}
}
}


//////////////////////// Forging midi bytes for the current song for protodeck updates ////////////////////
function output_midi()
{
for (x = 2; x < 15 ; x++)
{
if ( (x==2 || (x>=8 && x<=14)) )
{
for (y = scene; y < GRID_Y_SIZE + scene; y++)
{
if (clip_slot_grid[x][y].get("has_clip") == 1)
{
if (clip_play[x][y].get("is_playing") == 1)
{
if (clip_play[x][y].loop_status == 1) outlet(0, x + " " + y + " 32"); // green for looped clip playing
else outlet(0, x + " " + y + " 16"); // red for unlooped clip playing
}
else if (clip_play[x][y].get("is_triggered") == 1)
{
outlet(0, x + " " + y + " 48"); // yellow for clip triggered
}
else
{
if (clip_play[x][y].loop_status == 1) outlet(0, x + " " + y + " 64"); // blue for looped clip unplaying
else outlet(0, x + " " + y + " 96"); // cyan for unlooped clip unplaying
}
}
else
{
outlet(0, x + " " + y + " 1"); // off for no clip
}
}
}
}
}


//////////////////////////// Scrolling the view around //////////////////////////////
function next()
{
if (scene < (num_scenes - GRID_Y_SIZE))
{
scene += GRID_Y_SIZE;
output_midi();
}
}

function prev()
{
if (scene >= GRID_Y_SIZE)
{
scene -= GRID_Y_SIZE;
output_midi();
}
}


/////////////////// Handle clip,scene firing and transport calls from cellblock ///////////////
function fire(x, y)
{
if (x == "scene")
{
liveset_scenes[y + scene].call("fire");
}
else
{
if (clip_slot_grid[x][y + scene].get("has_clip") == 1)
{
clip_play[x][y + scene].call("fire");
}
}
}


//////////////////// Catch-all callback function ////////////////////
function device_callback(args)
{
switch (args[0])
{
case "id":

//
break;

///////////////// Handle empty clip slot /////////////////
case "has_clip":

var x = this.track ;
var y = this.slot ;
if (clip_slot_grid[x][y].get("has_clip") == 0)
{
if ( y>= scene && y<scene+GRID_Y_SIZE ) outlet(0, x + " " + y + " 1");
}
break;

///////////////// Handle changes in clip playing status /////////////////
case "playing_status":

var x = this.track ;
var y = this.slot ;

if ( y>= scene && y<scene+GRID_Y_SIZE && (x==2 || (x>=8 && x<=14)) ) // only fire midi bytes updates for the current observed scene & only for signifiant tracks
{
if (clip_slot_grid[x][y].get("has_clip") == 1)
{
if (clip_play[x][y].get("is_playing") == 1)
{
if (clip_play[x][y].loop_status == 1) outlet(0, x + " " + y + " 32"); // green for looped clip playing
else outlet(0, x + " " + y + " 32"); // red for unlooped clip playing
}
else if (clip_play[x][y].get("is_triggered") == 1)
{
outlet(0, x + " " + y + " 48"); // yellow for clip triggered
}
else
{
if (clip_play[x][y].loop_status == 1) outlet(0, x + " " + y + " 64"); // blue for looped clip unplaying
else outlet(0, x + " " + y + " 64"); // cyan for unlooped clip unplaying
}
}
else
{
outlet(0, x + " " + y + " 1");
}
}
break;
}
}

March 5, 2010 | Unregistered Commenterjulien

this is great! thanks for the script included Andrew! I like the part where you add properties/assign values (i mean fields) dynamically to the LiveAPI objects stored in the 2 dimensional Arrays like the clip_slot_grid . this really saves some lines and makes the iteration trough the states of num_tracks in the functions very fast. I m thinking of building a superclass with the basic grid functions for a matrix controller and proper children for the grid, mixer, devices so on. This instances could be kept in another array for easy switching between different pages/presets and could be used to populate the array recursively. Got to get my head more around this prototyping stuff. too bad JS has no include or package visibility.
But again awesome articel!

December 27, 2010 | Unregistered Commenterturrican

sorry, forgot to check the date, em..anyway Ive been looking for something like this for a long time

December 27, 2010 | Unregistered Commenterturrican

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
Some HTML allowed: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>