Passing thru Velocity only not Midi note

Jim Fallgatter

2009-08-20 08:17:01

Hello All….I am a new user and using a midi keyboard to drive a PC application via MT. My questions are most likely elementary…so feel free to refer me to existing posts/threads…which I have been studying but not yet found what I think I need:

A.
1. I translate the incoming midi note to a qwerty key that then…via this application sounds a different midi note depending on many variables in the PC application. Said a different way…the incoming midi note/qwerty key translation is fixed …but my application takes the qwerty key and directs which midi note to sound and this can be any midi note.

2. I would like to retain the incoming Midi note Velocity and use that simultaneously as the velocity for whatever midi note is called for by my application (via output for instance thru MS wavetable SW Synth).

3. Right now I have MT set to swallow the whole midi in.

Translator 1: New Translator
Options: stop=false
Incoming: MIDI 80 4F pp
Outgoing: Keystroke: Y


B.

1. On the same output note (1. above) I would like to be able to modulate the sound (pitch bend) simultaneously via foot pedal input to my PC (USB port) of any outgoing note sounding at that time as directed by my application.



C. I would appreciate any suggestions from the forum members as to a good pitch pedal controller that has been set up to work with MT via USB connection.

Thanks, in advance, so much for any suggestions on the above questions. Jim

florian

2009-09-07 22:57:58

Hi Jim,

just to make sure: are these questions answered in the other topic?

Thanks,
Florian

Jim Fallgatter

2009-09-08 00:13:34

Wow...you do a good job of watching out for completion. Thank you! The answer is no...although it might be my lack of understanding...but I still don't know if I can pass velocity along independent of a midi note.

A test for someone without my software...that knows how to 'read' what Bome is outputting would be to translate a midi note (from a midi keyboard) to a qwerty key (K for instance) in a application like MS Word (for instance)..while checking to see if velocity data (only...not the pitch) is forwarded to the synth concurrently with K appearing in the doc . My extensive notes under the other topic explain my software so I won't repeat why this is desired...but basically...my software provides the pitch (note) to be played. I am trying to provide the Velocity for that note.

Thanks again Florian for checking in on this. Jim

joesapo

2009-09-08 23:33:38

Your velocity data would still need a destination to route to... as far as I know, there aren't any qwerty keyboards that are velocity sensitive (How cool would that be tho! Just press really hard for a capital letter... lol).

First and foremost; MIDI messages in MT that start with '8' are Note OFF messages. Some MIDI keyboards will transmit velocity only on Note ON events, so make sure that you don't mean to have it as a Note ON (would be '90 4F pp').

If this were me, I would start by duplicating your translator and treating both actions (velocity transfer and keypress) as separate actions.

Code: Select all

Translator 1: Translator_Y_Keypress
Options: stop=false
Incoming: MIDI 80 4F pp
Outgoing: Keystroke: Y 

Translator 1: Translator_Y_Velocity
Options: stop=false
Incoming: MIDI 80 4F pp 
Outgoing: MIDI ?? ?? pp
Multiple translators can process on the same incoming action, as long as you don't have one of the translators set to 'Stop Processing with this translator.' Your first translator will trigger on the note, regardless of velocity and output the Y keypress. Your second translator will just handle the retransmission of the velocity value.

Unfortunately, that's the tricky part. You will have to find out *where* in your application to send the velocity value pp to. How does the program accept this value? Can it be input through MIDI, or perhaps as a keystroke somehow?

joe

Jim Fallgatter

2009-09-09 19:40:12

Hello Joe,

Thank you very very much for your reply and the corrected/expanded translator code. I want to answer your question completely about the output. Here is how my application works:

I will be labeling the midi keys as Alpha/numerics re a qwerty. My application GUI calls for a qwerty key to be pressed just like music notation calls for a piano key. So the first translator translates the midi key to a qwerty and I would like to simultaneously deliver the velocity for the midi note to my application's chosen synth output (for instance it now sounds thru MS wavetable SW Synth).

Does that help? Perhaps you are saying I need to provide some sort of code that identifies/sends the Velocity to the MS wavetable SW Synth??

Thanks imensely for bearing with me one more step on this. Jim

joesapo

2009-09-11 01:42:11

Jim Fallgatter wrote:Hello Joe,

Thank you very very much for your reply and the corrected/expanded translator code. I want to answer your question completely about the output. Here is how my application works:

I will be labeling the midi keys as Alpha/numerics re a qwerty. My application GUI calls for a qwerty key to be pressed just like music notation calls for a piano key. So the first translator translates the midi key to a qwerty and I would like to simultaneously deliver the velocity for the midi note to my application's chosen synth output (for instance it now sounds thru MS wavetable SW Synth).

Does that help? Perhaps you are saying I need to provide some sort of code that identifies/sends the Velocity to the MS wavetable SW Synth??

Thanks imensely for bearing with me one more step on this. Jim
Okay I think I'm following you...

I think the only possible way to do this would be to direct your outgoing MIDI signal (the one that would go to the SW synth) back into MT after it's been triggered by a keypress action.

Once you have it back into MT, you could potentially recombine it with the velocity value you captured from your global variable in your, for example, "Translator_Y_Velocity" translator.

Then from MT you can output the combined MIDI signal to the sw synth or wherever you'd like it to go.

Does that make any sense?

joe

Jim Fallgatter

2009-09-11 06:46:42

Hello Joe,

Thank you again. In concept and based on my ability to control both my input and output midi device (in MaxSeq) it is certainly worth a try...and seems much more probable than sending a dangling velocity value along without a solid pitch connection.

So...gosh...Joe I hate to ask...how in the world would you combine the two...without knowing which pitch is played by the qwerty key. Would it be based on the timing of the event...last pitch called for gets the velocity hooked to it?? Essentially a simultaneous event??

The song file (qwerty key/pitch relationship) is created in advance...and it can call for a particular velocity to be sounded...but of course this takes that musical gesture out of the player's hands...which defeats the whole purpose using a midi keyboard to do this.

So the question is can you combine a 'loose' velocity with a pitch...and the pitch coming back in could be anything. ?? It is a great idea...but I haven't the faintest how it could be accomplished??? I don't seem to be much help here Joe. Thanks, Jim

joesapo

2009-09-12 01:27:56

without knowing which pitch is played by the qwerty key
Is this correct? I was assuming in your application that a unique keypress would always output the same MIDI note.

If the MIDI note output from your application CAN be a 1-for-1 with the keypress that you assign to it, you should be able to map the keypress AND the resultant incoming value together in MT, combine them, and output them again to your sound source.

If the MIDI note output from your application CAN NOT be determined ahead of time, your best bet would be to base it on either a timer function, or simply to just reassign the 'dangling velocity value' to the next MIDI note coming in to MT from your application.

There would be some some problems with this, of course, if you were to play chords on the keyboard... MT wouldn't know which midi note to assign which velocity value. However, if you can say that for example, a 'K' keypress in your app would always output a 'C2' note, then you could;

1. capture the velocity associated with your K keypress as we talked about before
2. store the velocity in a global variable
3. listen for the K-associated note (i.e. C2) coming back into MT via your application
4. and tack on the stored velocity value from before in the outgoing MIDI message

It would have to look something like this;

Code: Select all

#Listen for a unique MIDI signal from your controller, output as a keypress and store your velocity value in a unique global variable 'ga'
Translator 1: MIDI_To_Keypress
Options: stop=false
Incoming: MIDI 80 4F pp 
Rules: 
  ga=pp
Outgoing: Keystroke: K 

#Listen for the MIDI coming back from your application, and replace whatever the velocity value is with what you had stored from the prior translator
Translator 2: Input_Signal
Options: stop=false
Incoming: MIDI 91 24 pp 
Outgoing: MIDI 91 24 ga 
Subsequent messages would just need to use a different global variable (there are tons) and you should be able to create a unique pair of translators to accomplish what you're wanting to do...

Please let me know if I can help any further... :D

joe

Jim Fallgatter

2009-09-16 06:21:30

Hello Joe,

Please excuse the delay in responding. You have understood the challenge exactly and I think you have proposed a super solution. Thank you very very much. I am now attempting to test this and will let you know the results. I think for a chord it will sound fine...even if produces a 'blend' of velocities...which in actuality might be the case with a keyboard in any case...that is the fingers, even if intended, don't really strike all the notes of a chord at the same velocity. Thanks again for taking the time to figure this out. Bests regards, Jim

Jim Fallgatter

2009-09-16 23:00:33

Hello Joe,

Well I thought I was on to this...but I guess not. So where I am stuck is that the MIDI output from my application CAN NOT (as you wrote to verify) be determined ahead of time. So I am wondering how to set this up to assign the "dangling velocity" (stored in a global variable, ie ga to the next incoming midi note or notes (in the case of a chord) perhaps on a First out, First in basis?? I understand that I would set up a global for every type of keystroke that my application uses...as you have suggested for keystroke: k With that in place if I played a chord I would store a PP for each note of that chord.

So the question becomes...what does translator 2 look like in this case...when it doesn't know what midi note(s) will be incoming. Is there a way that we can do it on a first out/first in basis. Maybe assigning a time stamp to the global variable when it is loaded with a velocity...and then continually pairing them up with whatever midi note comes in next based on the time stamp??

How to code this is of course the challenge. Joe I don't expect you to do this...but could you recommend someone I can pay to help me. I would be more than happy to do that. Thanks, Jim

joesapo

2009-09-23 01:24:14

Jim Fallgatter wrote:Hello Joe,

Well I thought I was on to this...but I guess not. So where I am stuck is that the MIDI output from my application CAN NOT (as you wrote to verify) be determined ahead of time. So I am wondering how to set this up to assign the "dangling velocity" (stored in a global variable, ie ga to the next incoming midi note or notes (in the case of a chord) perhaps on a First out, First in basis?? I understand that I would set up a global for every type of keystroke that my application uses...as you have suggested for keystroke: k With that in place if I played a chord I would store a PP for each note of that chord.

So the question becomes...what does translator 2 look like in this case...when it doesn't know what midi note(s) will be incoming. Is there a way that we can do it on a first out/first in basis. Maybe assigning a time stamp to the global variable when it is loaded with a velocity...and then continually pairing them up with whatever midi note comes in next based on the time stamp??

How to code this is of course the challenge. Joe I don't expect you to do this...but could you recommend someone I can pay to help me. I would be more than happy to do that. Thanks, Jim
Jim...

Sorry about the late reply!

I'd be more than happy to give you a hand with your template. If you're on Windows we can set up a remote assistance session with TeamViewer and either a chat or phone linkup to communicate.

I'm thinking we're going to have to go ahead and program your template to operate on a first out/first in basis and go from there. I'm thinking with a translator pair we should be able to track the incoming messages from your application based on octave ranges and timer values.

I'm fairly confident between Florian, Rudi and I we can get something working for you.

Shoot me an email at joesapo [at] gmail [dot] com and we'll plan from there... :D

Joe

Jim Fallgatter

2009-09-23 13:53:32

Hi Joe,

Thanks for the positive reply. That will be much appreciated. Per your direction I will be in contact next week to get on your schedule. My daughter is getting married this weekend and things have become very very hectic here. Thanks again!!! Jim

Jim Fallgatter

2009-11-26 01:36:13

Hi,

Trying to reach Joe. Joe are you still there? Jim