Jump to content

Assign Incoming Midi Channels to Different Notes on a Software Instrument


romatona
Go to solution Solved by polanoid,

Recommended Posts

Hi - I'm bringing in midi trigger info on 8 different midi channels from an external sequencer into a software instrument midi track in logic pro x and want to assign each midi channel to a different note on the selected software instrument (especially the drum kits like ultrabeat and dmd).

Anyone know the the best way of doing this?  

Thanks!

 

Link to comment
Share on other sites

  • Solution
44 minutes ago, romatona said:

Hi - I'm bringing in midi trigger info on 8 different midi channels from an external sequencer into a software instrument midi track in logic pro x and want to assign each midi channel to a different note on the selected software instrument (especially the drum kits like ultrabeat and dmd).

Anyone know the the best way of doing this?  

Thanks!

Do your MIDI triggers all send the same note pitch? If they don't (or if you can configure them not to), it is probably easier to use the note pitch instead of the note channel for instrument assignment. If you don't want to dive into MIDI Scripter programming or the MIDI Environment, at least for Ultrabeat and Drum Kit Designer AFAIK this is the only way. For DMD, if you are on Logic 10.7.x already, you can set the MIDI input port for the DMD Track Stack's sub tracks. Or create a Summing Track stack with 8 instances of e.g. Ultrabeat and use each instance to just play the notes generated by one of your MIDI triggers, and set each Ultrabeat track's MIDI input channel accordingly (possible in 10.7.x only as well).

Edited by polanoid
  • Like 1
Link to comment
Share on other sites

To clean this up a bit, here's the 5 approaches that come to my mind in a list:

1) Don't use the MIDI channel for separation, use the MIDI note pitch

2) Write a MIDI Script that only events from a certain channel pass through

3) Do something similar in the MIDI Environment (haven't thought of how exactly this would be done, but it would certainly involve one or more Transformers)

4) Upgrade to 10.7.4 and use DMD and the MIDI Input Port of the DMD sub tracks

5) Upgrade to 10.7.4 and use a dedicated track in a summing track stack for each of your MIDI triggers, set their MIDI input port appropriately

Edited by polanoid
  • Like 2
Link to comment
Share on other sites

Here you go:

function HandleMIDI(event) {
    if(event instanceof Note) {
        let p = GuiParameters.get(event.channel);
        if(p>0) event.pitch = p-1;
    }
    event.send();
}

/********************************************
 * Setup the GUI
 ********************************************/
 
var allPitches = ["(disabled)"];
for(let pitch=0; pitch<256; pitch++) {
    allPitches.push(MIDI.noteName(pitch));
}

var PluginParameters = [];

PluginParameters.push({
  type: "text",
  name: "Channel to Pitch Map"
});

for(let chan=1; chan<=16; chan++) {
  PluginParameters.push({
    type: "menu",
    name: "Channel " + chan,
    valueStrings: allPitches,
    defaultValue: 0
  });
}

var GuiParameters = {
   data: [],
   set: function(id, val) {
       this.data[id] = val;
   },
   get: function(id) {
       if(this.data[id] == undefined) {
           this.data[id] = GetParameter(id);
       }
       return this.data[id];
   }
};
function ParameterChanged(id, val) {
   GuiParameters.set(id, val);
}

1483178016_ScreenShot2022-07-31at6_37_26PM.thumb.jpg.5b3aac9b17de3987e93bf7a44d46355a.jpg

Edited by Dewdman42
  • Like 1
  • Love 1
Link to comment
Share on other sites

Hi - thanks so much for these suggestions which I've been working through and I've worked out how to adjust the note pitch rather than relying on the default channel separation which is working a treat. 

So useful to know the other options too which I'm sure will come in handy another time.

Thanks again!

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...