Forums > MaxMSP

Selector~ GUI Latching LED's?

Jun 18 2009 | 7:16 am


Easy one (hopefully…)

Please see the attached patch. Very simply I’d like to be able to have a visual indication of which wave has been selected using a red LED.

Where in the patch should I put the LED’s so that when "1" is selected (Sine) an LED lights up and stays on until I select "2" (at which point the "1" light goes out and the "2" light comes on, and so on…)

This seems like it should be easy but has me foxed.

Thanks as always.


— Pasted Max Patch, click to expand. —
Jun 18 2009 | 7:51 am

Here’s one way, using matrixctrl set to ‘1 per column’ – you could make your own LED graphic and use a blank background image,

— Pasted Max Patch, click to expand. —
Jun 18 2009 | 8:52 am

Decode and/or radiogroup will do exactly what you want. I just discovered decode a few weeks ago, its very very useful!

— Pasted Max Patch, click to expand. —

Jun 18 2009 | 9:07 am

Ah, Decode is exactly what I was looking for… thanks as always for your help!

Jun 18 2009 | 9:39 am

Only one problem… can the umenu be used to bang the selector as well as turning the LED on and off? It seems to bang on all outputs.

Jun 18 2009 | 9:58 am

If you hook up an integer box to the left-most outlet of umenu you will see that it outputs the index of the menu item chosen, starting at 0 for the first item in the list.

You can simply connect it’s left-most outlet to the left-most inlet of selector~, which will have exactly the same function as the message boxes.

Its important that you know the difference between a bang and a message to use max. You might want to go over max tutorials 2 and 3 if you haven’t already.

Jun 18 2009 | 10:23 am

of course… thanks for your help.

Viewing 7 posts - 1 through 7 (of 7 total)

Forums > MaxMSP