RealVision home
   
  DxMidi - Sending events  
Summary
Implementation
Availability
Sign In/Out
Setting buffers
Sending events
Receiving events
OMS support
Sysex support
Result codes

NoteON
NoteOFF
SendData
DurNote
Note

result = me.NoteON ( channel, note, velocity )
result as Integer
channel as Integer
note as Integer
velocity as Integer

Plays a note ON data command (3 datas are sent to Midi: status, note and velocity).
result code <> 0 if an error occured.

channel is the specified MIDI channel
(see MIDI documentation for more infos).
note is the MIDI note (1-127) defined in the MIDI norm.
velocity is the MIDI standard velocity (1-127) defined in the MIDI norm.

Don't overflow any value of the method, either you could have an transmit error.
The MIDI note is sent immediately.



result = me.NoteOFF ( channel, note )
result as Integer
channel as Integer
note as Integer

Plays a note OFF data command (3 datas posted to Midi, status, note and velocity = 0).
In fact, this is always a Note ON command, but with velocity = 0.
result code <> 0 if an error occured.

channel is the specified MIDI channel
(see MIDI documentation for more infos).
note is the MIDI note (1-127) defined in the MIDI norm.
The standard MIDI defined a Note OFF velocity, but in most of cases, this parameter is absolutely useless.



result = me.SendData ( myString, mode )
result as Integer
myString as String
mode as Integer

This command is useful to send SysEx and controls. The method will send the packet with a mode to autorize sending more than 248 midi packets (for SysEx).
result code <> 0 if an error occured.
mode
is the flag for : starting packet, end packet, continued packet, packet to be continued.
You can use this to send notes, but it’s better to use the NoteON method. You can send Controls, Program changes, short and long SysEx events.
myString is a RB-Waste string (larger than 32k), it contains the datas to transmit.
If you want to send a SysEx longer than 248 bytes, send multi-packets and set the mode parameter to inform the Midi driver that the datas are not finished.

this is the values for
mode :

NoCont 0 This first packet is not continued.
StartCont 1 This is the first packet of a multi-packet message
MidCont 3 This packet is the following of a long message, and not the end
EndCont 2 This packet is the following of a long message, and this is the end !

Don’t use NoCont to terminate a long multi-packet message. NoCont is just the default.

Examples soon...



result = me.DurNote ( channel, note, velocity, duration )
result as Integer
channel as Integer
note as Integer
velocity as Integer
duration as Integer

Synchronous version only to send notes with duration (1/60 of a second).

result code <> 0 if an error occured.
channel is the specified MIDI channel
(see MIDI documentation for more infos).
note is the MIDI note (0-127) defined in the MIDI norm.
velocity is a velocity MIDI value (0-127)



result = me.Note ( note, velocity )
result as Integer
note as Integer
velocity as Integer

This is a different version of NoteON() method. This method uses the
chan control property to affect the output of notes. This could simplify send of notes from windows to create midi effects (arpeggiators, delays, etc...).
result code <> 0 if an error occured.
note is the MIDI note (0-127) defined in the MIDI norm.
velocity is a velocity MIDI value (0-127)