split midi range

Dec 2, 2013 at 10:59am

split midi range

Hello,
i´m new here and my very first question is how could i split the midi range 0 – 127 in for example 0 – do nothing, 1 to 20 (Message 1), 21 to 40 (Message 2), 41 to 60 (Message 3) and so on……
I tried out different nodes and checked out the tutorials…but i didn´t come forward….pleas help.
thx

#274433
Dec 2, 2013 at 11:22am

use the exp object or vexpr object.

#274434
Dec 3, 2013 at 3:48am

Thanks for your reply. But i didn´t figured out how to use the exp/vexp objects. But i got an i idea how to fix my problem. Maybe it´s not the convenient way how i used to do it. See the example in the attachement. Thx.

Attachments:
  1. split_midi.maxpat
#274504
Dec 3, 2013 at 4:27am

<code>

– Pasted Max Patch, click to expand. –

</code>

#274511
Dec 9, 2013 at 12:36pm

Thanks, Vichug. I´m on Win with Max 6. Are these externals available for Max6/Win7? I guess just for Mac or Max 5 on Win. Nevertheless thx.

#275247
Dec 9, 2013 at 2:55pm

[expr (($i1>0)*($i1>=20))*1 + (($i1>20)*($i1>=40))*2 + ($i1>40)*($i1>=60))*3]
|
[select 1 2 3]

or

[expr ($i1>0)*(($i1/20)+1)]
|
[select 1 2 3 4 5 6 7]

-110

#275261
Dec 9, 2013 at 2:58pm

or

[* 0.05]
[+ 1]
[coll]

#275262
Mar 26, 2014 at 6:12am

thank you, sorry for beeing late with my reply. This works fine, but is there an option that if a number occurs in these ranges just one bang is outputted and the other numbers in this range are getting ignored? I´m sorry for bother you again. I has had a look at the onebang objekt, but it doesn´s seems to work in this way.

#284977

You must be logged in to reply to this topic.