Page 1 of 1

Light Script for various actions

Posted: 09 Jan 2013 11:17
by NsiCharles
Hello all, I am new to the lemur app and editing and would like a boost in the right direction. I don't necessarily need step by step instruction, just a nudge in the right direction or an explanation of what I should be looking at to learn what I want to do. Here goes,

First and probably most simply and important, I'd like to figure out how to create a script that:
Turns one switch light off because another switch has become activated.
Second:
In my ohm64 script I have a red box that outlines a group of five columns. I can move this box up and down with the midi controller, and as I move the box up and down I can use the same pads (1-5) to trigger the selected 5 clips in the column. Is there a way to create a box like this within ableton for the lemur or a way to use only 5 switches/pads to trigger a whole set moving down the line? Attached below is a screenshot of the box Im speaking of.

I hope this is not too confusing, but I would really appreciate any help or nudges in the right direction or suggestions as to what I should study or research to learn how to do this myself.

Thanks,
-Charles

Re: Light Script for various actions

Posted: 10 Jan 2013 07:54
by Softcore
For your first question...

Lets say we have switchA and switchB...And we want switchA to go off when switchB is turned on.

Add a script in switchB on expression x, any

Code: Select all

if (x==1) switchA.x=0;
edit: or even simpler,
Add a script in switchB on expression x, rising from 0 (up arrow)

Code: Select all

switchA.x=0;
keep in mind, that if one of the buttons will always be active by default, then you dont need the script at all, you just need to enable the "radio" setting for an array of switches. With this setting enabled, whenever a switch is turned on in the array, the previous one is turned off.

I suspect however, that you are asking this because you are planning to use them as "clip triggers" in Ableton Live. If that's indeed the case, you might be better off by setting up your whole Lemur project so that the actual midi feedback from Ableton back into Lemur controls whether the switches are off or on. Also in this case, I believe the choice of "pads" would be better as inherently, "clip triggering" in Ableton Live by midi controllers happens with push buttons - note ons - pads rather than switches. To better comprehend this, if you use a switch and you try to re-trigger the clip, it will re-trigger each second press instead of each press - try with a pad to see the difference.

Now on to your second question, this "red box" is really a feature of Ableton Live and created when specific Ableton Live control surfaces are being used. These are available in the top menu of the relevant midi settings of Ableton Live and are in fact stored in your computer as .py scripts. Check-search for the folder resources - Midi Remote scripts (inside the installation folder of Ableton Live) and you will understand what I mean.
Now, to have such a box, one should know how to program a midi remote script for Ableton Live. Google for "Midi remote scripts Ableton py" and lots of results will provide info.
Also check out http://modern.dj/app/
It offers an online utilty-tool to create your own midi remote script - you get to define the dimensions of the "red box" (how many tracks it covers, how may scenes it covers) and the midi messages the gird buttons will have. I have tried it, but unfortunately the "feedback" controlling the on-offs was eratic so I gave up on it. But perhaps after studying all the rest of resources you might come up with your own py script.

Your last bet, I reckon, will be to wait for LiveControl2 by the makers of Lemur which I believe will offer the functionality you are after, out of the box.

edit: By the way, another approach would be to emulate the midi messages your ohm64 sends in Lemur and then "trick" ABleton Live into thinking your Lemur is just another "ohm64" (add it as a control surface) and have your second "yellow" (red box is the first, yellow is the second control surface added) box.

Re: Light Script for various actions

Posted: 11 Jan 2013 03:40
by NsiCharles
Wow, what an incredible response. Thank you so much for your input. After comprehending the screenshot you've included in your post, I'm slowly starting to understand what I will need to learn to make complex setups within the lemur app. This is quite entertaining and satisfying!
I suspect however, that you are asking this because you are planning to use them as "clip triggers" in Ableton Live. If that's indeed the case, you might be better off by setting up your whole Lemur project so that the actual midi feedback from Ableton back into Lemur controls whether the switches are off or on.
Ok, so what would I need to do to make ableton tell the Lemur this sort of thing using midi communication instead?

Thanks again for the help,
I really appreciate it!
-Charles

Re: Light Script for various actions

Posted: 11 Jan 2013 18:54
by Softcore
Unfortunately (and Im saying unfortunately because it involves further coding which Im not an expert on), the best way I can think of is again, .py scripts or MaxForLive custom device.

As for comprehending scripting Lemur (which really really enhances and adds to what it can do) I strongly reccomend downloading lots of user library projects which may contain stuff to help you understand how things (and codes) work. Find litle bits of "features" you 'd like to incorprate in your own designs and "figure" them out - Im also a beginner in all of this too! ;)

Also, as cliche as it may sound, a read on the manual about scripts or even trying one or two of its examples as tutorials can really set the basics down - switching a button off with another button being one of them! ;)

Re: Light Script for various actions

Posted: 13 Jan 2013 17:44
by mat
Hey all,

for light interaction with abletons pattern slots, this thread can be also interesting:
http://liine.net/forum/viewtopic.php?f=25&t=1040
There I attached some kind of "modular" channelstrip for Ableton. It gets light feedback from pattern (including blinking) via midi. Scripting and values to adept are also explained in the thread... but it does not match the red box thing in Ableton, as patternslots are midilearned and not dynamic.

Another option to scroll through a big Live set is to use Abletons "Scene up","Scene down", midimap it to pads and also pads for track start and stop. That way you can step through the scenes and start special patterns - however, visual feedback will force you to look at the monitor...

cheers*
mat