I guess the obvious thing is to bind the input from Lemur to a rack gain, and bind the rack gain out to Lemur, so changing one will always change the other. And when you load a song, the rack gain stored in the song will be sent out to Lemur at song load time, to initialise Lemur. The only potential problem is that when you move a Lemur fader, Cantabile will echo the fader value back to Lemur, which I guess could cause problems, especially if you’re moving faders quickly, and in particular, if Lemur then echoes this back into Cantabile…
So ideally what you need is to disable the MIDI route going out to Lemur for a particular fader, when the last thing that modified the fader was Lemur itself. I haven’t tried this, but you might be able to achieve it as follows:
- Set up an embedded rack, which internally just routes its Rack MIDI In to Rack MIDI out. Route the rack’s MIDI output to Lemur.
- Set up your incoming binding from Lemur to your chosen rack gain fader (I think you could use the embedded rack’s fader for this if you wanted).
- Add another binding that’s triggered when Lemur sends controller data for your fader, and have the target to send an unused controller message to the embedded rack MIDI in with a specific value (e.g. CC 110, value 127). Just make sure it’s a controller message Lemur doesn’t use itself.
- Add a binding that’s triggered when the fader is tweaked in Cantabile, and have the target to send the same unused controller message to the embedded rack, with a different specific value (e.g. CC 110, value 0)
- Right-click on the route inside the embedded rack, go to MIDI Route Settings, and in the “Condition” area, set up a rule that allows the route to work only if that above controller is not equal to the value set up in step 3 (i.e. 127 in my example). In other words, disable the route if the last controller message modifying the fader was from Lemur.
- Finally, set up your outgoing binding for your rack gain fader, sending it to the embedded rack. Make sure this binding is after the above bindings.
What should happen is that the embedded rack should act as a switch, breaking the route out to Lemur when Lemur is controlling Cantabile, and re-enabling the route when the Cantabile fader is moved (or initialised at song load) to allow it to notify Lemur. Well, that’s the theory!
Like I say, I haven’t tried this, and it’s rather fiddly, but it might just work. If it does, it might be worth encapsulating the fiddly logic into a re-usable rack, so you don’t have to reproduce the fiddly steps each time, and for every fader.