|
Post by John Tennison on Sept 23, 2017 15:59:05 GMT
The MIDI note mapper is a very useful and vital part of MidiBridge for my work. Does MIDIFire have the MIDI note mapper available?
|
|
nic
Soapbox Supremo
Troublemaker
Press any key to continue
Posts: 2,011
|
Post by nic on Sept 24, 2017 12:46:42 GMT
Hi John,
Currently, you can remap notes using the Stream Byter.
I will gradually migrate more of the MidiBridge modules over in future updates.
If you need Stream Byter example rules to remap notes, just let me know.
Regards, Nic.
|
|
|
Post by John Tennison on Sept 24, 2017 14:51:37 GMT
Thanks, Nick.
This is great news. Yes, I would love the Stream Byter examples for MIDI note remapping.
Nonetheless, I look forward to a dedicated Note Mapper being available on MIDIFire, as having a graphic representation of the remappings is helpful. Also, I don't know if it makes a difference, but if a dedicated module allows for fastest response, that is very important to me.
In some of my applications, I remap ALL 128 MIDI notes in ways that are not the same within each octave. So it is VERY important to continue to be able to specify what each individual MIDI note number will be mapped to, rather than specify the remappings only across a single octave, which then repeated across all other octaves (as some manufacfurers do). MIDIBridge's capacity to specify each individual note remapping, and have multiple notes remap to the same note will continue to be an important function for me.
Nic, once again, I LOVE your products. From the bottom of my heart, THANK YOU for bringing the vision of MIDIbridge and more into the 64 bit realm.
Best wishes,
John Tennison (AKA Nonjohn)
|
|
|
Post by davvoy on Sept 24, 2017 18:31:04 GMT
May we get a bunch of Examples for use to Learn MidiFire? Like Scripts, Presets, Scenes, etc?
|
|
nic
Soapbox Supremo
Troublemaker
Press any key to continue
Posts: 2,011
|
Post by nic on Sept 25, 2017 11:19:27 GMT
OK, here is how to setup a full 128 note remap table in the Stream Byter. First, you probably want to refer to this midi note table to get hex equivalents for note numbers. Now, let's create a neutral table for remapping notes: # mapping table IF LOAD ASS L00 = 00 01 02 03 04 05 06 07 08 09 0A 0B 0C 0D 0E 0F ASS L10 = 10 11 12 13 14 15 16 17 18 19 1A 1B 1C 1D 1E 1F ASS L20 = 20 21 22 23 24 25 26 27 28 29 2A 2B 2C 2D 2E 2F ASS L30 = 30 31 32 33 34 35 36 37 38 39 3A 3B 3C 3D 3E 3F ASS L40 = 40 41 42 43 44 45 46 47 48 49 4A 4B 4C 4D 4E 4F ASS L50 = 50 51 52 53 54 55 56 57 58 59 5A 5B 5C 5D 5E 5F ASS L60 = 60 61 62 63 64 65 66 67 68 69 6A 6B 6C 6D 6E 6F ASS L70 = 70 71 72 73 74 75 76 77 78 79 7A 7B 7C 7D 7E 7F END
# note mapping logic IF M0 >= 80 # lowest note off IF M0 <= 9F # and highest note on ASS M1 = LM1 # lookup/replace note END ENDThat doesn't actually do anything! To modify the table, proceed as follows: Choose a note you want to map from and to, for example: map MIDI note C0 to D3 note C0 is hex 18 and D3 is hex 3E Locate '18' in the above table (second line in mapping table) and replace it with '3E' Repeat for other notes. That's the basics of a mapping table. Now, you don't have to do a full table if you're only remapping a handful of notes; instead you could remap only individual notes purely with simple rules like: NX 18 = XX 3E # remap C0 to D3Finally, let's say you want to transpose a range of notes, example transpose MIDI notes C0 to B0 by 2 semitones # transpose notes C0 to B0 by +2 semitones IF M0 >= 80 # lowest note off IF M0 <= 9F # and highest note on IF M1 >= 18 # and C0 and higher IF M1 <= 23 # and B0 and lower MAT M1 = M1 + 2 # transpose +2 END END END ENDIt's possible to do all sorts of remapping stuff, but I'm the first to admit that the Stream Byter is not for everyone, so if you would like me to create remap rulesets for you, just list the from and to notes you want remapped and I will do it for you in the most efficient way. Regards, Nic.
|
|
|
Post by John Tennison on Sept 25, 2017 12:59:43 GMT
Thanks, Nic.
|
|
|
Post by John Tennison on Sept 26, 2017 1:27:41 GMT
Nic,
The mapping table works great! Thanks.
There is one other thing I need to do in Stream Byter.
I need to convert incoming MIDI note-ons to CC values, but I need to add 4 to the value of the CC before sending it out.
For example, I would like to have all incoming Note-ons be converted to CC 6, but with 4 added to the CC value before sending it out. Also, want to maintain the same channel as the original MIDI note-on. Also, I want filter out (i.e. Cancel) all note-off events, such that they are not translated into anything.
So for example, if I play a C3 on the keyboard, rather than send out a 3C hexadecimal value for CC6, I want Stream Byter to send out a hexidecimal value of 40 for CC6 (which, of course, is 3C plus 4).
If this is possible on Stream Byter, I am wondering what the simplest code would be that would allow this process?
Thanks,
John Tennison (AKA Nonjohn)
|
|
nic
Soapbox Supremo
Troublemaker
Press any key to continue
Posts: 2,011
|
Post by nic on Sept 26, 2017 8:34:20 GMT
I think I understand. You want to use the note on velocity + 4 as the value for CC 6 which gets sent for each note on.
The rules below will generate the CC (and suppress all other events, so only the CC is sent out of this module)
# generate CC6 for each note on IF M0 >= 90 IF M0 <= 9F IF M2 > 0 # we have a note on
# convert to CC, preserve channel MAT L0 = M0 + 20 # add 4 to note number MAT L1 = M1 + 4
# issue complementary CC SND L0 06 L1 END END END
# block all events XX = XX +B
Regards, Nic.
|
|
|
Post by John Tennison on Sept 26, 2017 12:47:57 GMT
Thanks, Nic. I will try it now.
As I have said before, I LOVE your products!
|
|
|
Post by John Tennison on Sept 26, 2017 13:20:58 GMT
I tried the code above, and realized after trying it that I had not communicated clearly.
Is not the velocities that I want to add a fixed value of 4 to. Rather, I want to effectively transpose all incoming note values upward by 4 semi-tones before converting them to comparable CC6 value. That's what I had meant by "adding 4". I realize now that I had not been clear.
The 4 semi-tone transposition should remain fixed for all incoming note-on events.
Note-on velocities can be ignored. And I still need note off events to be blocked.
|
|
nic
Soapbox Supremo
Troublemaker
Press any key to continue
Posts: 2,011
|
Post by nic on Sept 26, 2017 13:45:49 GMT
I just modified my code above so that the incoming note number + 4 is then sent as the value of CC6
Still not really sure if this is right though. Maybe if you explained what you are trying to do at a higher level I may catch up?
Regards, Nic.
|
|
|
Post by John Tennison on Sept 26, 2017 16:08:06 GMT
Nic,
The modifications you made were exactly what I needed. It works perfectly.
Essentially, my application is using an 88 note MIDI keyboard to specify exact continuous controller values for a synthesizer on which I am performing. I do it with both CC6 and various other controller numbers (e.g. filter, resonance, etc.) However, since the keyboard only has 88 keys, I had empirically determined that the most musically expressive range of the parameter I was controlling for a particular synthesizer was actually four increments above the CC values that the note-ons would generate. For this reason, I needed to add 4 to the note-on value. Of course, I could have transposed the keyboard with its own internal software, but I wanted to have a dedicated module to do it for me, and has often been the case, Stream Byter was just the ticket.
Thanks for creating GREAT software. I look forward to the continued evolution of MIDIFire.
-John Tennison (AKA Nonjohn)
|
|
|
Post by John Tennison on Sept 27, 2017 12:08:49 GMT
I am having the time of my life playing with MIDIFire.
There is one other mapping that I need to do with Stream Byter.
I need to be able to play a note-on into MIDIFire and have that converted into a several CC commands.
It could be any MIDI note. For example, let's use Middle C received on any MIDI channel..
If I play middle C on any channel, I need Stream Byter to generate the following commands on ALL 16 MIDI channels:
A value of 0 for CC 1 A value of 127 for CC 7 A value of 0 for CC 64 A value of 0 for CC 91 A value of 0 for CC 100 A value of 2 for CC 101 A value of 0 for CC 122 A value of 127 for CC 120 A value of 127 for CC 123
|
|
|
Post by John Tennison on Sept 27, 2017 12:56:11 GMT
Oops, I just realized I made a typo in my specified CC values. CC 100 should be a value of 2 and CC 101 should be a value of 0.
So the CC values that I need Stream Byter to generate upon receiving a MIDI note would be:
A value of 0 for CC 1 A value of 127 for CC 7 A value of 0 for CC 64 A value of 0 for CC 91 A value of 2 for CC 100 A value of 0 for CC 101 A value of 0 for CC 122 A value of 127 for CC 120 A value of 127 for CC 123
|
|
nic
Soapbox Supremo
Troublemaker
Press any key to continue
Posts: 2,011
|
Post by nic on Sept 27, 2017 14:25:34 GMT
OK, this will require two seperate Stream Byter modules chained together, one to generate the CCs on channel 1 (it will not pass on any incoming events) and another to clone incoming events on channel 1 to all 16 channels.
First, to generate your CC's
IF LOAD ASS K0 = 3C # middle C, change this END
# force channel to 16 XX = XF
IF M0 == 9F IF M1 == K0
# trigger note found, send CCs # on channel 1 SND B0 01 00 # CC1, 0 SND B0 07 7F # CC7, 127 SND B0 40 00 # CC64, 0 SND B0 5B 00 # CC91, 0 SND B0 64 02 # CC100, 2 SND B0 65 00 # CC101, 0 SND B0 7A 00 # CC122, 0 SND B0 78 7F # CC120, 127 SND B0 7B 7F # CC123, 127 END END
# block all incoming XX = XX +B
Then, put this in the second Stream Byter to explode to all other 15 channels
XX = X1 +C XX = X2 +C XX = X3 +C XX = X4 +C XX = X5 +C XX = X6 +C XX = X7 +C XX = X8 +C XX = X9 +C XX = XA +C XX = XB +C XX = XC +C XX = XD +C XX = XE +C XX = XF +C
I just typed this all in freehand. There might be syntax errors.
Regards, Nic.
|
|