Pattern sequencer for live performing

You mean how to tell the MIDI File Player to start at the next 1?

1 Like

Yes exactly, I hadn’t expressed that neatly.

Ok, so for in example in the 1st song part a MIDI sequence is playing and when you switch to the next song part then another MIDI sequence should be started by the next bar ?
and the previous midi sequence should be stopped?

1 Like

Since Part 1 is usually the click track, it should run constantly. Alternatively I could use the system metronome and route it to another output.

Midi sequence 1 runs as soon as I press play. If I then switch to Part 2, another midi sequence is added, which then does not trigger a click, but a sample in contact. If I jump back to part 1, because e.g. the chorus is over, part 2 should also stop directly on the next 1.

MIDISync.gig (19.9 KB)
Try this

Load the gig file and load a midi file in the MIDI File Player called “Sample”
Switch to SetList Mode and start global play.
Now when you switch to the 2nd song part the MIDI File Player “Sample” is started with the next 1 beat.
When you switch back to the 1st song part it is stopped by the next 1 beat.

2 Likes

Bro, this is exactly what I was looking for! Great.

One last question. I would need up to 8 patterns instead of just 2. Is there a practical way to expand this? Then I would have my pattern sequencer as desired :). Awesome.

With widgets you can select the active song.

Assign the Parameter “SongNummer” of the MIDI File Player to a widget.
So in each variation you can select a different song (=MIDI sequence).

2 Likes

I haven’t looked at @pianopaul 's gig file as to how similar or different it is from the gig file I was referring to. However, the song selector widget is similarly used to select the media file in the midi file player, along with a widget to start playing the file.

So since you already got the song part to start correctly on the next 1, what you do in this solution is send midi commands programmed in the song file part. If you open the song file part editor, there’s a midi helper where you can add midi messages you want to send. You would drop a virtual midi port, and send midi message to the widgets to select the right file and to the widget to start playing the file.

So basically each song part would select a different file in the midi file player, and send the play command to start playing that file. I hope I explained it clear enough. If not, tomorrow I can sit in front of the gig file and see what I missed. Lol

2 Likes

Guys, you are great. Thanks for your help.

I was able to work well with Paul’s file. But the combination of both files would actually be the ultimate, because then I can trigger the midifiles in time, as well as switch variations quanitized.

I have now loaded ztones file again.
Enclosed 2 screenshots. I have now used the songpart selector. At the intro/verse where no sample should sound, I simply selected another song. At the chorus, where a sample should sound, I selected the corresponding song. This is at position 1 in the midifile player.

The only thing that does not work: When I go back from the chorus to the intro/verse part, the sample continues to play. What could be the reason for this?

The midifile triggers the note C2 with a maximum length (value 127). The sample has 16 bars and is looped. So I can play it continuously for long choruses. But if I go back to part 1, it should always stop - no matter at which position I am.

Thank you and greetings Michael


I just noticed autocorrect messed up what I was trying to say earlier. When I said “song file part”, I meant song part.

I just want to make sure I understand. You say it triggers a note. Are you saying it continues to loop or that there is a stuck note (note off not received)? If it continues to loop and you are you using 2 midi file players, then you’ll have to create another widget to start / stop play when changing song parts and add those commands to the song part properties midi helper section so that when you switch back to part 1, it stops the play of part 2 MFP.

I use 1 MFP and use the system click (you can edit the sound if you don’t like the default). When using a single MFP, when you chose another file to play, it automatically stops the play and you only need to send a start play for the newly selected song part. In my gig file I have this automated in the GIG SCRIPT so that I don’t have to add that command to each song part. I can’t remember if quantized song parts gig file I referred you to has this (or similar) in the GIG script file?

Var 
    IAC_Driver_Bus_1 : MidiInDeviceAlias
    Gate_Open : Boolean = true

On Song(oldSongIndex : integer, newSongIndex : integer)
    InjectMidiEvent("Local GP Port", MakeControlChangeMessage(80, 127))
    InjectMidiEvent("Local GP Port", MakeControlChangeMessage(80, 0))
End

// Called when you switch to another songpart
On Songpart(oldSongpartIndex : integer, newSongpartIndex : integer)
    if newSongpartIndex == 0 then // Assumed the first song part is to stop the MFP
         InjectMidiEventViaRigManager(IAC_Driver_Bus_1, MakeControlChangeMessage(2, 0)) // Stop MFP
    elsif newSongpartIndex <> oldSongpartIndex then
        Gate_Open = true
    else
        Gate_Open = false
    end
End

// Called when a CC message is received from the IAC virtual midi port
// CC 1 is used to select the MFP Song Number
On ControlChangeEvent(m : ControlChangeMessage) Matching 1 from IAC_Driver_Bus_1
    if Gate_Open then
        InjectMidiEventViaRigManager(IAC_Driver_Bus_1, m) // MFP Song Number
        InjectMidiEventViaRigManager(IAC_Driver_Bus_1, MakeControlChangeMessage(2, 127)) // Play MFP
        Gate_Open = false
    end
End

That automates the start/stop play MFP so you don’t have to add it each time. However, that’s assuming you are using a single MFP. I hope this helps.

Hey ztones,

thank you - I will try it tomorrow, since I’m away for 2 days. The problem is not that the sample loops constantly, but that it plays through once completely - no matter if I jump back to Part 1 in the meantime.

If I jump back to Part 1 after 8 bars, for example, the sample simply plays another 8 bars until it finally stops.

Greetings Michael

Hey all,

I wanted to give you guys an update here and afterwards I have a question.

The script works great - thanks again! I can switch within the Rackspaces click-based between the variations always to the next 1.

What currently is still a problem is the switching between the rackspaces. Is there a solution for this?

Concrete example: I have a medley that has 130 bpm. For this I have created 3 rackspaces. In the setlist mode I can switch them seamlessly and the click runs cleanly. However, rackspace 2 and 3 each start with a sample or midi arpeggio, which triggers a sound. While the variations always switch to the next 1, the rackspaces switch with the push of a button. Thus sample and midi arpeggio do not start parallel to the click, and the whole thing is untight. But if I then press Variation 1, it is right from the next bar on.

Can I switch across Racespace so that it changes to the next 1 or does that require a script?

Thanks and greetings,
Michael