Forums > MaxMSP

stop changing level

Apr 30 2011 | 9:01 am

quite a confusing one so bare with me:

Im trying to take a reading from a sensor to control a slider in max, but i want to make it so when i take my hand away from the sensor the slider doesn’t go back to its original position. to make it harder the sensor is outputting a number continuously.

can anyone suggest an object or series of objects that can help with this?


Apr 30 2011 | 9:15 am

this is a fairly common request, and depending on the exact desired functionality, there are several objects which apply; I think you need to examine [change +], [change -] or [past].


Apr 30 2011 | 11:12 am

hey thanks,
I’m not too sure they will help, im not too sure what i want to do is possible as im using infrared sensors to control say a volume slider in abelton. this means that i need to be able to adjust the level again once i have set it the first time.
the only way i can see round it is by making something that measures the speed of the hand movement so if you bring you hand in quickly from the side it will take a new reading, but if you raise your hand slowly it will record the movement.
do you know any objects for that?


Apr 30 2011 | 6:16 pm

[change +] will output a 1 when the number stream is rising, therefore you could keep a [gate] open with it; use [==] to determine the delta of the number stream and close the gate when it’s 0; ne c’est pas?


May 02 2011 | 2:01 pm

I think i see what you mean, but that still doesn’t really help.

Iv had another thought though,

-- Pasted Max Patch, click to expand. --

This is what i came up with, the only problem I have now is every time the sensors detects the slightest of movements it plays the note again. do you know how i could get round this?


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

Forums > MaxMSP