General

D0 - Channel pressure question

Started by Softcore on .

Sign in or create an account to join the conversation.

18 posts

Topic starter
Ok so...Im building something and the following questions occured to me...

1. What is the "standard" (if any) behaviour of a midi keyboard equiped with channel pressure messages in regards to what happens AFTER the user releases a key? Does the channel pressure value return to 0 or does it stay at the last value it was before the user lifted his finger? It makes sense that it goes to 0 (pressure is indeed 0 after all) but if one is to map it to a fairly audible parameter on his synth, after lifting the finger the "difference" in the sound timbre is too, ermmmm, disruptive in some cases - due to the channel pressure value "jumping" to 0 , the result depending on where channel pressure has been used as a modulator isnt that much "musical". Perhaps thats for the user to consider when using it as modulation source or is it that on an actual midi keyboard the pressure value "decays" to 0 after lifting the finger?

2. If the user has a key pressed, and a second key is pressed, does the channel pressure "jumps" from the first value (first finger) to the last (second) or something else happens?

Anyone knowledgeable to reply? Thanks in advance!
Hi SC . . . I believe the info at your posted link is slightly misleading as regards nomenclature.

Aftertouch and Channel Pressure aren't different things. The author of that particular piece is taking two different names for the same (class of) thing and assigning one name to be correct for "channel" and the other to be specific to "polyphonic".

IOW . . . "aftertouch" and "pressure" are interchangeable. The difference of note is "channel" versus "polyphonic" (or simply "poly").


As to the answer to your real question - have you looked into the little-used but very handy Release Velocity? That seems like it would be a good fit as a modifier to control what happens to any Pressure messages upon releasing a key.

Whether or not it's supported in your DAW or other destination of choice is anyones guess.
Thing is, they ARE different in regards to MIDI - D0 is channel pressure....A0 is key pressure (aftertouch, or polyphonic aftertouch as some manufacturers name it)

The reason though Im asking is not because I want to decide on how to modulate my synths...rather on how to correctly implement the feature on my design of a "Lemur velocity and pressure/aftertouch midi keys" template. (think something like the keys of Animoog where the position of the finger on the key defines velocity and pressure/aftertouch) . Obviously, my second question is irrelevant for Key pressure - polyphonic aftertouch where each key generates its own pressure midi values. According to the link above, when we have channel pressure though, an average is calculated (from the pressures of all keys) and being sent - or simply by using a single pressure sensor - ok, so we got my second question covered.

;)

But my number 1 question is:

While testing the functionality, I mapped the key pressure to the pitch of an oscillator in a synth and it occured to me - everytime I lift my finger, a pressure value of 0 is sent, my question is not whether me as a user desires this or not but rather what an ACTUAL midi keyboard would do - would it send a pressure 0 value or it would just send nothing after lifting the finger from the key? ;) If of course this behaviour is standardised amongst manufacturers.
Hi
Thinking of how it is physically implemented may help . .
As the key is pressed it hits a pressure sensor, you can then vary the pressure , and it decreases to zero at some rate as you release the key . . .
how this informs your implementation ? i am not sure . . There is a fundamental interface difference . . .
Perhaps you need to look at some provision for values to ramp down at different rates . .
So Yes the values should go down to 0 as you release the key . .
Just off the top of my head . .
Cheers
MM
Yeah - D0 and A0 are different controller numbers - but they're both aftertouch / pressure. One channel, one poly.

I'm just saying the guy's mixed up in nomenclature - not that channel and poly pressure / aftertouch are the same thing (I know the difference).

And my post wasn't really aimed at you, more FTR - I presumed you knew the story! :D

I'm not sure all manufacturers implement CP properly either (as the mean of all pressed keys) - some opting to just sample the first key pressed or whatever.

Does Lemur support Release Velocity? I'm not sure how it could unless sensors in the touchscreen can track the surface area of a depressed finger or thumb, for instance. So I think Macciza's thinking here is correct . . . fundamental differences in the hardware will require some sort of compromise / workaround - maybe something like the lagging-fader to set a rampdown upon key-release?
yes, there are two kinds:

a) monophonic aftertouch. AKA channel aftertouch. Every middle-class keyboard has it. One parameter is sent, regardless of the key number.
b) polyphonic aftertouch. AKA key aftertouch. Only few high-end keyboards have it. It's expensive, because each key has an individual pressure sensor.

Now, what means 'pressure'? Is it a) or b)? In hardware, it is rather clear, it's mostly a), if the keyboard costs less than $2000.

But, on the target side there are also restrictions. Not many synths or samplers can receive b). Even software instruments.

Touchscreens offer today the possibility to output b), which is an enormous possibility because you don't have to spend a fortune for poly aftertouch anymore. For example, I can play the Largo and Diva VSTi with SynthX's MIDI out in full polyphonic aftertouch, something I can't do with all hardware keyboards available to me. This is just great, a dream came true. I'm only beginning to explore this potential. In Diva, b) is simply called 'Pressure', and without knowing which kind of AT it is I had to try.

Now, for the question: I don't know how real keyboards featuring b) send poly AT values; I planned to get such a keyboard, but never got one unfortunately. Yeah I also guess it goes to zero after release.

I'm very interested in your findings.
Also
I generally go to the source to check MIDI specs http://www.midi.org/techspecs/midimessages.php

Channel Pressure (After-touch). This message is most often sent by pressing down on the key after it "bottoms out". This message is different from polyphonic after-touch. Use this message to send the single greatest pressure value (of all the current depressed keys). (vvvvvvv) is the pressure value.

Well it depends on how quickly you have released the pressure off the keys . ..
I seem to recall that you could get 0 values by reducing pressure but still having the keys held - ie note still on
Cheers
MM
Its true that most of my VST synths I tried respond ONLY to channel pressure and not the true, polyphonic aftertouch messages (I tried using Lemur).

And yeah, if it goes back to 0 I also think a ramp down with a user-definable rate should be implemented.

As for release velocity a "compromise" could be made - it already has been made in various midikeys implementations in ipad synths - usually the y position of the finger on a key when pressed indicates the velocity - one could make it so that the y position of the finger when the key is released determines the Release Velocity although that is not what Im after - Im after key/channel presure data as the end user (including me) is most likely to have a compatible VST synth for these values rather than Release Velocity! ;)

As I was typing Macciza replied: Thanks for the link Macciza - I will check it out!
Phil999 wrote:yes, there are two kinds:

a) monophonic aftertouch. AKA channel aftertouch. Every middle-class keyboard has it. One parameter is sent, regardless of the key number.
b) polyphonic aftertouch. AKA key aftertouch. Only few high-end keyboards have it. It's expensive, because each key has an individual pressure sensor.

Now, for the question: I don't know how real keyboards featuring b) send poly AT values; I planned to get such a keyboard, but never got one unfortunately. Yeah I also guess it goes to zero after release.
perhaps you know-have investigated what happens in a)? I mean after releasing a key (lets say we pressed only one) what happens to channel pressure? Jump to 0, ramp down to 0 or no message at all?
Yeah . . . Release Velocity is one of those messages not widely supported, just like Poly Pressure, and presumably for similar reasons - cost to build individual sensors per key. Thinking about the hardware for a second, it's likely that the same sensors would be useful for sensing both values.

However, and here's where you might score big - I'm not sure your VST has to support RV so long as you DAW does, and can map / assign this to whatever parameter you wish to control.

This is what I used to do back in the good old Atari Cubase days to gain some extra realtime controllers - ironically using channel and poly messages painted into the key editor. I was fortunate enough to have a rack workstation synth that responded to poly, although of course I didn't use it as intended (as it was clearly intended to take the everloving p*ss out of MIDIs bandwidth).
Softcore wrote:perhaps you know-have investigated what happens in a)? I mean after releasing a key (lets say we pressed only one) what happens to channel pressure? Jump to 0, ramp down to 0 or no message at all?
I don't know either. Both masterkeyboards I bought in the last years do not feature AT, not even mono AT. That wasn't very wise. I once had a PPG PRK FD which surely had mono AT, but it stopped working eons ago unfortunately. Mmmh, really. Such a nice keyboard it was. On top of it, legend said it belonged to Andreas Vollenweider before, a good and famous musician which I adore very much. Sorry, I digress. Old memories.

polyAT.jzml

Hmm, with this approach the poly AT values remain where they were left after release. I have no idea if this is of any help for you, for me it is the first poly AT template ever. Maybe I can use it some day. It would need some dynamic resizing like in the SynthX app to be a real useful keyboard controller, but I guess this won't be too difficult to make.
Hi
It is also one of those mis-named one . . . - it is a NoteOff / velocity message . . .
Same as with 'Aftertouch' - its Polyphonic Key Pressure and Channel Pressure . . Aftertouch is a nickname / advertising slogan

Physically there is a sensor that is affected by all the keys - this sensor generally outputs the largest (channel) pressure which is why that is the result you get . . . You would need poly key pressure sensing to average it out

Message flow would be something like NoteOn velocity, then varying values 0-127 as pressure varies , highest value used as fingers change, then final pressure value reduces to 0 before NoteOn vel 0 or noteoff triggered. . .
There is no other physical way to do it really. Notes can be on with Pressure of 0 and have to transit back to 0 before note offs are possible . .

Cheers
MM
I wouldn't call it misnamed - it is the correct name, though you're of course correct in that it isn't a separate parameter in its own right, rather the third byte in a genuine NoteOff msg.

All that aside, I feel the whole idea of using Pressure msgs from the iPad to be a bit . . . skeuomorphic? Just forget about the notion that it ought to behave like the real thing and embrace the idea that it can behave as you (dynamically) wish perhaps?

[edit]

Thinking about it . . . NoteOff Vel is probably how I saw this referred to more officially, Release Vel colloquially.
Well i didnt know that - about the Note off velocity - I might as well implement that too!

@Phil: Yeah, ufortunately I wasnt that wise either - I dont even have a monophonic aftertouch keyboard (channel pressure). I will send you my approach this afternoon since you are also interested in this! ;)

Its a concept testing with ONE midi key sending note on (transposable via "octave selection" buttons), velocity and aftertouch (the monophonic one, channel pressure)
The thing is - and my thinking could be totally wrong on this of course - implementing NOV is probably as tricky as any of these other "what happens when I let go of the controller" CCs.

That is, you can technically implement them easily enough - but the hardware is different enough that they don't make a lot of sense in this context?

What I'm trying to say is, anything you can attach to these CCs for parameter-change could just as well be attached to any other CC (if indeed you need to use a fader or similar). On the other hand . . . there might be some sort of sensor apparatus on the iDevice that tracks the surface area of your finger when it's in contact with the screen - and if there is, and you can get access to it you can then calculate CP, PP and NOV with relative ease.

This will be a job for Liine to implement into the core app, if the sensor data is extant and available - but it would go a long way to bridging the gap between the hardware of a traditional keyboard and the touchscreen.

Anyone looking for a fairly cheapish way to experience (at the least) CP - the Novation Impulse line of controller kbds support it. Not fantastically well IME - but probably as much to do with the fact I'm no keyboard player as anything else.

This thread sponsored by: Ford & Lopatin