Now this isn't a tutorial about building a device in M4L, annoyingly I am going to assume you can do this already or are willing to learn how to. Rest assured with everything installed it is very straightforward and generally requires little or no actual 'programming' and is essentially about wiring components together on a design canvas and configuring them so they behave in the way you want. From our previous blog we are going to build this:
So let's explain what each component does.
Generally going from left to right, the 'loadbang' object is basically a trigger to execute something. It does not care what that something does rather it's 'go do whatever it is you do...'.
In this case it runs the 'nk.midi.sys' library you downloaded and installed earlier. The 'mxj' bit is a standard M4L object that allows external Java to be run. Yep, you guessed, it executes java, in this case our external library.
Essentially the library is wired to an M4L MIDI Out port 'chooser' to populate a user selectable list of available MIDI Out ports. It in turn is wired to the 'nk.midi.output' library. It is this library that ultimately is going to send our little piece of SysEx to our synth. So now we have established the machinery that deals with the MIDI port handling we can now concentrate on a control that can send dynamic values to our synth.
Again referring to our previous blog we saw how we constructed a SysEx message to statically modify the TVF Cut-off Frequency in Partial #1 or Part #1 on a Roland D-110. In this example we are going to add a control that dynamically constructs a SysEx message so we can edit in real time.
At top centre we have added a Live dial and set it's properties on the design canvas to work in range of 0-100, which is the numeric range our TVF Cut-off parameter understands. The output of the Live dial is sent in two directions.
The reason for this is that we want to not only get the value of the dial but unfortunately we also have to calculate the correct checksum for the message otherwise our D-110 will complain, remember the pesky checksum from the previous blog?
For every value change we need to re-calculate the checksum. The Live dial value is stored in an M4L Message object, the other branch is wired to an M4L EXPR object that essentially allows us to do a calculation, in this for the checksum. The object takes the input and embeds it into the formula from the previous blog, the only difference being that the formula is reflected in C-like notation. The output of the EXPR object is stored, just like the Live dial value, to an M4L Message object.
Now before we get to the final bit, we said previously that the natural language of SysEx is hexadecimal however M4L only understands integers and floats. In the bottom right corner we have an M4L Message object that largely contains Integer representations of all the static hexadecimal elements of the SysEx message.
It also contains a '$1' and '$2' parameter. Each of these parameters represent the Live dial value and the calculated checksum derived from the outputs of each of the branches and concatenated together using an M4L ZL object, which is essentially used to do the concatenation.
The resulting parameters are then inserted in to the final, now integer based SysEx message. This is finally wired to the MIDI output library. We have also added an M4L Flush object just in case something goes wrong in the buffers.
So we compile the device, grab a mouse and turn dial and watch in amazement as the value changes on your synth. Take it one step further and map an external controller to it. I bet you never thought you would editing a D-110 with a hardware knob directly within the DAW.
From my own personal experience the interaction is very responsive. There is always the chance that limited MIDI buffers on the instrument and other issues may affect performance and I have heard that can happen. Personally I've not experienced it, even extremely rapid dial movements result in instant value changes on the instrument. As always I offer the universal caveat 'Your mileage may vary...'.
Hopefully however you can see how SysEx and editing your external legacy synths can be dragged kicking and screaming into the 21st century. Certainly from an Ableton and M4L perspective there is no end to how creative you can get with building editors, the layouts are completely up to you to design and customise for your own purposes.
The next obvious step is then patch management and I can tell you that all of that is possible too, so go nuts!!
Jason Durbin (aka Lagrange Audio) has been a synth and music tech enthusiast for 30 years since getting his hands on his first synth in 1983 at the tender age of 16. He hasn't earned a single Aussie dollar from music but the journey has been nothing short of incredible and he has met and interacted with some amazing people along the way. Jason is a true enthusiast doing it for nothing more than the pure love of it.
Many fixes and tweaks to the range, official release of SH-101 plug out
We take a look at two Eurorack modules