Generate control values

kmll's icon

How can I generate values in max to be used to control other objects. E.g. a LFO. I tried to with [cycle~] but I believe this is only used for signal values and not for control.

Nick Holmes's icon

LFOs are also signals. [cycle~] works, but [phasor~] might work better for you. Have a look here:
https://cycling74.com/tutorials/lfo-tutorial-1-the-zen-of-the-silent-patch/

Roman Thilenius's icon


if you build a "phasor" object in max using metro + line, the rest will be almost as for signal LFOs.

kmll's icon

Thanks for the replies and the very interesting link. However I have created a very simple patch but shouldn't this be outputing values? It stays at 0.

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

Nick Holmes's icon

It works for me, if I turn the audio on (either from and [ezdac~] or from the audio status dialog).

seejayjames's icon

Yes, audio must be on for any ~ objects to work (with a few exceptions).

kmll's icon

Thanks for the advise. There was an issue with my audio setup but I got it working fine now.

What objects can I use to do similar things. I know I have [cycle~] and [phasor~] but are there any other objects I should check out. Maybe there is a random curve generator?

Roman Thilenius's icon


so you have given up using non audio objects?

Nick Holmes's icon

I know I have [cycle~] and [phasor~] but are there any other objects I should check out.

[phasor~] can be used to make all kinds of repeating waveform.

Maybe there is a random curve generator?

[noise~] for, er, noise. [noise~] -> [snapshot~] for a more S&H kind of thing.

kmll's icon

Thanks for the advise, I will test out noise :-) (what is S&H??)

Roman Thilenius, I would also like to experiment with non audio objects but do you have a chance to give me a quick sample patch I can review?

Nick Holmes's icon

S&H is "Sample and Hold". It's exactly what you would imagine [noise~] -> [snapshot~] would do - low frequency randomness.

Miles Davies's icon

Here is a random modulator I find useful

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

seejayjames's icon

If you want to make LFOs, experiment with cycle~ first. You can do a huge number of things with changing frequencies, adding and multiplying them together, etc. Also send cycle~ into the right inlet of other cycle~s and crank it up...listen to it too!
At the end of the signal chain, you can run through snapshot~ or number~ to get float values (-1 to 1) for use, if needed.

kmll's icon

Thanks for all the good advises and the random modulator above :-)