Open MIDI Project Settings…
Open the MIDI Project Settings window. You can set the project-specific MIDI values here. The settings here are not ‘General MIDI — GM’ settings.
Some very interesting things which might be of value, like the MIDI Thru settings. Investigate.
General MIDI settings in Logic Pro — Apple Support
Instrument Without MIDI Thru Function pop-up menu: The instrument selected here does not pass events through the computer when the instrument is assigned to the selected track. Normally, you would set the No Output instrument here (chosen by default).