Generic support for grid style control surfaces, starting with the Novation Launchpad Pro MK3


This question is more about development in general and less about a specific problem that needs troubleshooting.

I have a Novation Launchpad MK3 that I would like to integrate with Ardour.

The Launchpad is just sending MIDI messages in response to button presses. Functions like “Shift”, the volume faders, track muting, etc. are all implement by the DAW.

I read some of the existing comments on this forum and it seems the general recommendation is to copy an existing implementation for a control surface and just adapt it.

This is fine and I suppose it works for all the existing control surfaces, it will work for the Launchpad Pro as well.

What I’m trying to figure out right now is a way to maximize the return on my invested time if I decide to work on this. (In this context, a better return means that the work I did could be reused to support other applications)

If implement support for the Launchpad Pro within Ardour, then it will only work within Ardour of course.

Supporting other applications would need additional work.

Ardour is not the only software that I use and I would like to be able to use the controller with others. Or with hardware synthesiser, or who knows what in the future…

I have a few initial (naive) assumptions that make me think that I could build a middleware application that sits between the Launchpad Pro and other applications:

  1. The middleware application could be a state machine which would process all the input from the controller and then would send out MIDI messages according to a set of rules.
  2. The output of the middleware then could be integrated with Ardour via a Generic MIDI control surface mapping
  3. Adding support for additional grid-style controllers could be done via configuration files

The theoretical benefit would be that certain functions like translating the grid buttons into volume faders, and then just outputting a single CC message when the user slides their finger on the grid could be handled by the middleware and then it could be used by other applications via MIDI mapping.

The theoretical risk is that what I’m trying to do is not practical and I would invest my time just to get something that is inferior compared to adding support directly in Ardour.

An alternative solution could be to create a library that implements a state machine and can be configured via files but I don’t know how that would fit with the intentions of the developers.

I read that a lot of code is duplicated between control surface implementations. Maybe a solution similar to this could support grid style controllers that fit under the same umbrella.

What I need help with is feedback from people who have a better understanding of the internals of Ardour and the possibilities of the Generic MIDI control surface.

And as I said earlier, many things above are naive assumptions from my part, so if I made a mistake or if I oversimplified something then of course I’m willing to acknowledge that.

I don’t believe that a “middleware” approach is viable for this. The communication needs to be duplex, and so all that middleware really does is to move the API that has be supported for a specific device from ardour’s libs/surfaces to the middleware.

Grid style controllers are already included in our control surfaces. They are not a new thing for us. We have dedicated support for the Push 2 and Maschine variants already, for example.

In current 6.9 there isn’t much you can really use the pad of a grid-style controller for, other than a replacement for a MIDI keyboard. In 7.0 Ardour will support clip launching, and in that context, grid style controllers have many more uses. That code is still under development, and it’s not clear quite how things should work.

In general, if you in a timezone somewhere between European Central and US Pacific, it is likely more time efficient to come and discuss this sort of thing with us on IRC.

I’m in Sweden. I will try to find some IRC client and reach out there.

In the meantime:

You are right about moving the API out from Ardour, or in this case, not putting it in, and of course, the communication has to be duplex.

My impression was that there wasn’t any generic grid style controller support in Ardour, and the code that supports the devices you listed are device specific.

The idea was that the Generic MIDI control surface would send feedback and the middleware application would decide what to do with it.

I.e. setting a volume fader and providing feedback would involve a CC message being sent back and forth between Ardour and the middleware. The middleware then would store the feedback value and translate it into several MIDI messages to turn on the appropriate grid buttons if the mixer “view” happens to be active on the controller. When the user engages the mixer “view” and uses the “faders”, the opposite would happen.

In very simple terms, the controller lacks any sort of “brain” right now. What I’m exploring is to create an application that would act as a “brain” and then other applications would talk to the “brain” application instead of the controller.

The somewhat abandoned “ctlr” software somewhat represents the approach you want to take. If you haven’t looked at it already, it would probably be worth your time.

1 Like

Can you link a source? My search came up empty-handed.

Could it be this one?

After some thinking I decided to wait until the trigger box feature is released. The Launchpad doesn’t have much use until then.