Push Programming Oct13 01

From Cycling '74 Wiki
Revision as of 02:52, 4 October 2013 by Darwin Grosse (Talk | contribs)

Jump to: navigation, search


So, to start off this October 2013 Push Development series, I start with a device that does something I like to call frequency mixing. I use frequency mixing a lot during live performance, taking a static track and using some interactive EQ tricks to create a more interesting mix out of a single loop.

What we are going to do is to create an 8-band EQ/mixer, then hook it up to the button matrix of the Push. With a little tweaking, you should be able to use this information to access the buttons for almost any use you can image!

The Basic Max Patch

Download the first version of the device here:

In order to make sense of the patch - and to help you understand the process of making a patch Push-aware - we are going to start with a Max-only patch, then add Push content as needed. So, we have to start off with a basic Max for Live device that provides all of the tools necessary for doing frequency mixing.


You will notice that this device is missing some of the controls seen on the video - most particularly the "smoothing" function and Push device selection. These are specific to the Push itself, so we are going to ignore them for now.

Looking at the basic patch reveals the basic technique. We have sliders that control the overall volume of each of the EQ bands, controls that allow selection of the band "breakpoints", and the mysterious "8-cross" subpatchers that seen to be affecting the audio. Also, we take some values output by the 8-cross subpatcher and use them to light up a multislider object.


A few details to note. First, if you open the inspector for the level sliders, you will see that their range is set from 0 to 7 - a total of eight stages. Convenient, since the Push has eight buttons in the matrix for our use. In order to get a useful volume range (from 0% to 175%), I multiply the packed values by .25 - giving us volume values that allow for a decent cut or boost. The Reset button simply sets everything to 100% as a good starting point.

Also, in order to make our level displays "hyperactive", I have a vexpr object that multiplies the volume levels (reported by the left 8-cross subpatcher) by the value of the meters control. Since that meters control goes up to 10.0, it means that the display might be 10x higher than the actual volume; but as you will see, this is actually a useful way to interact with this particular visualization.

Finally, we can double-click on the 8-cross subpatcher to see what is inside:


Rather than using a filter or other typical EQ device, I'm using a set of cross~ objects to emulate an eight-stage crossover network. Since cross~ provides a 3rd-order - but fairly neutral - filter, using them in series works out. They also sound right to my ears for this particular application. If you aren't familiar with the cross~ object, you may want to refer to the reference manual or extended ref pages.

With this basic patch, you should be able to manually get some of the results that I achieved with frequency mixing. The next step is to control these changes with our Push device.

Finding our Push

In order to make anything work at all, we need to find the Push among the devices that we have connected to (and recognized by) Ableton Live. While I could dive directly into the Live Object Model (LOM) - and I probably will do so later in the month - I'm instead going to use some Max code provided by Ableton's own Push Guru: Mark Egloff.

Mark has provided me with some code that he developed for his own us, and is willing to share with all of us. This breaks down the connection to the Push into easy, always-available tags, and is going to allow us to get our device going in a hurry. Here's Mark's code:

When you un-zip the file, you will have a folder that follows the "packages" format for Max 6. Place this folder in the packages folder of your Max distribution and you will have access to the code as a series of clippings. Let start our Live connection by using some of this code to attach to our Push device.

Within our device patch, open the contextual menu (Right-click on Windows, Ctrl-click on Mac), select Paste From... -> Ableton Push -> Global.ControlSurfaceSelector. This will drop the control surface selector code into your patch from the clippings file. This code fires whenever the patch is loaded, and will fill the menu with all of the available control surfaces. From here, we can select our Push.


For this patch, the only thing I want to see is the menu, so I remove everything else from Presentation Mode. Now, we have to tie this selection to the rest of the system. Select the Global.ControlSurfaceManager from the same contextual menu. It will take a while to load - this is because all of the "guts" of the system are in the few objects that will be pasted into the patch. Connect the selector to the message box that contains "path control_surfaces $1" and you are ready to rock.


If you want to see if things are working, just hit the button matrix or other control; you should see information show up in the message box connected to the receive objects.