I thought I'd post this question to see if other Forumites with more experience with MIDI editing could provide some suggestions to try to solve a MIDI related problem.

In the last few weeks, I decided to take some favorite MIDI files that I have collected over the years and import them into BIAB (2011). I have successfully imported the chords and melody tracks from about 60 MIDI files, but 1 or 2 of them exhibit a strange problem that I haven't been able to isolate and/or remedy (as of yet). I don't want to spend an inordinate amount of time or effort trying to figure out what's going on, but I thought someone may have run across this already, or know where to look for the source of the problem.

What I generally do is open the MIDI file first in Realband to examine its structure and identify the tracks for the melodies that I want to capture in BIAB. Most of these arrangements are pretty complex, requiring import of multiple channels from the source file in order to capture the good sound of the original file. Using the "Import chords from MIDI file" function, after inspection of the source file in Realband, I decide which channels to import to the Melody and/or Soloist tracks of BIAB. After importation, I then (usually) use the sequencer mode within BIAB to rechannel the imported tracks, so they don't appear on the channels used for the BIAB styles (2,3,6,7, and 10 plus Thru Channel 5). After selecting the appropriate style to go along with the melody, these files are then saved as .MGX files. In a few instances, with simpler, less complex melody tracks, I have been able to import the note information from the original MIDI file into the Melody or Soloist track, and then use the BIAB patch change features to change the Melody or Soloist track as needed to achieve the desired results, then saving that file as an .MGU file.

The problem that I have observed with two MIDI files that I have imported is that the song plays fine the first time it is run in BIAB, but when BIAB loops the song back to play again, or if you manually click “Play” after the song has played one time, one of the re-channeled tracks (comprising part of the melody) has a problem with correct sound playback on the second or subsequent playbacks. Usually only one of the re-channeled tracks is affected, and the problem is that some of the pitch bends during the second or subsequent playbacks of the song are not played correctly for that channel.

I need to indicate that I use an external MIDI synth, the Roland SD-50. I suspect that during the initial playing of these problem song files, there is some MIDI controller event somewhere in the body of the song that gets sent out to the SD-50, which affect playback on the second and subsequent runs. I have done some troubleshooting, and I have found that for one of the problem songs, the “rogue” event is near the end of the song, and for the other problem song, it is near the middle of the song. However, there are thousands of events to look at, making isolation of the exact cause a daunting task.

I have found that the only way to "fix" these problem files is to manually send a "GM Mode ON" message manually from BIAB to the SD-50 before trying to re-play the song. I looked at the MIDI Monitor and saw that the "GM Mode ON" message sends a Controller 122 message with the data value = 127 to all 16 MIDI channels (this is the Local Control ON message).

Of course, I can mentally flag these two songs and remember to send the "GM Mode ON" message after playing them as a “work-around” for the problem (I would also want to send this message so that it doesn't mess up any other song that is played after it), but if it is not too complicated to imbed some additional MIDI events into these two files to take care of the problem automatically, that would be preferred. I did try to manually add the “Local Control ON” message at the beginning of all of the imported channels for one of the songs (which has 10 imported channels divided between the Melody and Soloist tracks), but that didn't fix the problem, which still occurs during the second playback. I didn't add the” Local Control ON” message to the BIAB channels used by the BIAB style because I don't think they are being affected by the problem, and also I don't think that you can do this in BIAB (probably have to go back to Realband.......getting too messy for me!). I would think that if there is some sort of MIDI event sequence that can be appended onto the END of these files, which can reset "normal" operation, this would automatically fix the problem when re-playing these files (or any other file loaded after it).

Any thoughts and/or suggestions would be appreciated.

Thanks,
Dave R.