Synth Forum

Notifications
Clear all

Send sysex to Modx from forscore

5 Posts
3 Users
0 Likes
957 Views
Posts: 0
Eminent Member
Topic starter
 

Hello everybody.
I normally use Forscore to send Program Change messages to my Modx.
Now, I need to have a "hold-on" only one key of the modx (for ex. A2), and while he plays, in the meantime I improvise with the Moog. Then after the performance with the moog, I should deactivate the "hold key" and continue playing with modx. I know something like this can be done by sending CC64 messages to Modx ... what kind of CC message can I send from forscore (on sysex format), first for "hold-on" and then "hold-off"?

 
Posted : 20/07/2021 6:52 am
Jason
Posts: 7897
Illustrious Member
 

SysEx and CC are different. You do not send a SysEx if you want a CC and you do not send a CC if you want a SysEx.

CC #64 is the sustain switch. A value of 0 = off and 127 (decimal) = on.

You would send (in hex)

0xBn 0x40 0x7F (where "n" is the Part number minus 1. or just 0). 0x40 is 64 decimal (the CC Number). 0x7F is the value (sustain ON). 0xB0-0xBF indicates CC with n=0-F (and n is the MIDI channel number minus 1).

0xBn 0x40 0x00 indicates sustain OFF.

If you can send note on and note off messages with Forscore - then just send a "NOTE ON" midi message and do not send a NOTE OFF until you want to stop holding.

A NOTE ON message starts with 0x9n (where "n" is the Part number minus 1). A NOTE OFF message starts with 0x8n

The full format for NOTE ON would be 0x9n 0x00-0x7F 0x01-0x7F.where the first byte after 0x9n is the MIDI note number (0-127 decimal) and the next byte is the velocity (any number 1 or higher to 127 decimal). A velocity of 0 turns this NOTE ON message into a NOTE OFF message.

The full format of the NOTE OFF would start with 0x8n and have the same two bytes following as above. With NOTE OFF 0x8n, the 3rd byte (corresponding to velocity of NOTE ON) is ignored.

You could send 0x90 0x40 0x7F if you wanted Part 1 to start/hold MIDI note 0x40 (40 hex) at maximum velocity. This would hold until a note OFF message follows which could look like 0x80 0x40 0x00 or 0x90 0x40 0x00

 
Posted : 20/07/2021 7:24 am
Posts: 0
Eminent Member
Topic starter
 

In the meantime, thank you for your willingness to explain these concepts to me, which are a bit difficult for me.
So if I understand correctly:
0xBn 0x40 0x7F = sustain ON (on channel n)
This way I would have control of the sustain pedal via midi and the note will continue to play
0xBn 0x40 0x00 = sustain OFF (on channel n)
This will break the sustain pedal

Obviously in a patch where I use, for example, 9 sounds in layer, I will have to replicate the sysex by setting the midi channel number instead of n:
For example...
0xB1 0x40 0x7F = sustain ON (on channel 1)
0xB2 0x40 0x7F = sustain ON (on channel 2) ... and go on
Exact?

 
Posted : 20/07/2021 7:43 am
Jason
Posts: 7897
Illustrious Member
 

0xB1 0x40 0x7F = sustain ON (on channel 1)
0xB2 0x40 0x7F = sustain ON (on channel 2) ... and go on

MIDI Channels are numbered 1, 2, 3 ... through 16.
MODX has "Parts" 1-16 numbered the same way 1, 2, 3 ... through 16.

When MODX is in multi-channel mode, Part 1 corresponds to MIDI Channel 1, Part 2 corresponds to MIDI Channel 2, and so on through Part 16 which corresponds to MIDI Channel 16.

0xBn has this funny "n" which you replace with the ZERO-based MIDI channel. This n has different numbering than the above Part or MIDI channels. The "n" value should subtract one from the desired Part/desired MIDI channel above.

0xB0 has "n=0". We know that "n" is one less than the corresponding Part number. 0xB0, n=0 corresponds with Part 1 or MIDI Channel 1
0xB4 has "n=4". This corresponds to Part 5 or MIDI Channel 5

The reason why the value is zero based for the low-level MIDI command is that this is the language the computer and electronic devices speak in. The value of "0" is used as the first value because the computer is comfortable doing so. The concept of Zero as "FIRST" in a list is not common for people. When you make a grocery list, you probably do not list it as:

0. Eggs
1. Bread
2. Milk

... starting with zero. The presentation for people adjusts these zero-based values to one-based values which is why Part and MIDI channel start with 1.

Computers and programmers are fine with starting with 0. Consumers are typically more comfortable with starting with 1.

Your question is a programming type of question - so you also need to become comfortable with zero vs. one based in order to effectively use these values.

 
Posted : 20/07/2021 4:23 pm
Bad Mister
Posts: 0
 

Hello everybody.
I normally use Forscore to send Program Change messages to my Modx.
Now, I need to have a "hold-on" only one key of the modx (for ex. A2), and while he plays, in the meantime I improvise with the Moog. Then after the performance with the moog, I should deactivate the "hold key" and continue playing with modx. I know something like this can be done by sending CC64 messages to Modx ... what kind of CC message can I send from forscore (on sysex format), first for "hold-on" and then "hold-off"?

Perhaps an understanding of the Controller will help. The Sustain function on electronic keyboards, by itself, does not guarantee the key you want to hold will continue to sound… you must also consider the Envelope Generators that control what happens to the sound while cc64 (Hold) command is triggered On. On electronic keyboard “sustain” takes the place of you holding down the key… what happens to the instrument sound will be determined by its Envelope Generators (Amplitude EG for how loud, and Filter EG for the tone/timbre).

Just because you hold down the Sustain pedal (or send cc64 =On) this does not guarantee your instrument will continue sounding… if it is an instrument in the percussion family (hammered, struck, or plucked) most likely the sound will last a bit longer than usual but it will eventually fall to silence (according to its programmed AEG). A drum will not sustain, a piano will but it does not sustain indefinitely

Instruments that have an AEG where “Decay 2 Level” is something other than 0, (bowed or blown instruments) will sustain indefinitely (meaning as long as the key is held or the sustain pedal, cc64, is held.

“Indefinitely” is not really a musically relevant term, as music seeks to control the *when* and *when not* of things sounding.

If your goal is to extend the sound while you play on another keyboard, or a different Part, you might look to just working with Amplitude Envelope Generator of the sound in question (unfortunately, you don’t reveal what it is).

But it maybe as easy as raising the “Release” Knob for the Part in question… the dedicated “Release” Knob found in the Quick Edit area, let’s you instantly “offset” how long it will take for the sound in question to disappear once you stop engaging the key. Placing that Part’s Release parameters so they are readily accessible can mean a simple gesture (turn the Knob clockwise) to increase the time it holds with a key on message, and a simple gesture (turn the Knob counterclockwise) to return it to normal. (Release is cc72)

Explore the instrument you wish to do the “hold” and then decide on the most convenient/efficient way to accomplish the goal.

Extra Credit:
Don’t let zero throw you. If you ever played a sport with a clock, you know how to (and why we) count up from zero. The first minute is identified with a zero, a colon, and then 2 digits that count the seconds: sixty seconds in each minute, and numbered 0 through 59. When the fifty-ninth second is complete, you have played for an entire minute. The first half minute of a soccer match is 0:30, the second minute of the game starts at 1:00
0:00 ~ 1:00 is one complete minute on a clock.

As a musician you don’t necessarily count time like a clock. You start playing at measure 001. The top of measure 001 to the top of measure 002 is one complete measure of music.

You don’t need Sysex to do what you wish to accomplish. You simply want the last note to hold while you do something else. There are several ways to accomplish this using (user friendly) CC messages.

 
Posted : 20/07/2021 5:47 pm
Share:

© 2024 Yamaha Corporation of America and Yamaha Corporation. All rights reserved.    Terms of Use | Privacy Policy | Contact Us