Copyright © 2013-2015 MultiMedia Soft

MidiDjConsole.ProfileButtonMidiCommandGet method

Previous pageReturn to chapter overviewNext page

Remarks

 

Obtains parameters of the short MIDI command specific for a button item stored inside the profile. See the MidiDjConsole.ProfileButtonMidiCommandSet method for details about the structure of a short MIDI command representing a push button item.

 

The combination of MIDI command parameters is usually defined inside the technical specifications of the physical DJ Console and may vary a lot depending upon the DJ Console in use.

 

For further details about interfacing with MIDI DJ Consoles see the MidiDjConsole object section and the How to manage MIDI DJ consoles tutorial.

 

 

Syntax

 

[Visual Basic]

control.MidiDjConsole.ProfileButtonMidiCommandGet (

strItemName as String,

nMidiCommandPressed as Integer,

nMidiCommandReleased as Integer,

nMidiChannel as Integer,

nMidiDataPressed as Integer,

nMidiDataReleased as Integer

) as enumDjcErrorCodes


 

[C++]

short control.MidiDjConsole.ProfileButtonMidiCommandGet (

BSTR strItemName,

short *nMidiCommandPressed,

short *nMidiCommandReleased,

short *nMidiChannel,

short *nMidiDataPressed,

short *nMidiDataReleased

);


 

Parameter

Description

 

 

strItemName

String containing the name of the push button item.

If no push button item with this specific name should be available inside the profile, the method would fail and would return an error code.

nMidiCommandPressed

Reference that, on return from the method call, will contain the number representing the MIDI command issued when the physical button is pressed. In many cases the value of this parameter is 144 (hex 90) which indicates a "Note On" MIDI command.

nMidiCommandReleased

Reference that, on return from the method call, will contain the number representing the MIDI command issued when the physical button is released: in some case this value could be identical to the value returned inside the nMidiCommandPressed parameter in which case the pressed/released status would be identified by different values of the nMidiDataPressed and nMidiDataReleased parameters below.

nMidiChannel

Reference that, on return from the method call, will contain the number representing the MIDI channel.

nMidiDataPressed

Reference that, on return from the method call, will contain the number representing the "Data" parameter of the MIDI command issued when the physical button is pressed.

The "Data" parameter is a 16 bits integer value which combines 2  bytes ("Data1" and "Data2") which usually indicate the code of the pressed button and its status (pressed/released).

Separate values of the "Data1" and "Data2" bytes can be extracted from this parameter using custom functions and/or macros.

nMidiDataReleased

Reference that, on return from the method call, will contain the number representing the "Data" parameter of the MIDI command issued when the physical button is released.

As mentioned above, the "Data" parameter is a 16 bits integer value which combines 2 bytes ("Data1" and "Data2") which usually indicate the code of the pressed button and its status (pressed/released): in some case this value could be identical to the value returned inside the nMidiDataPressed parameter in which case the pressed/released status would be identified by different values of the nMidiCommandPressed and nMidiCommandReleased parameters above.

Separate values of the "Data1" and "Data2" bytes can be extracted from this parameter using custom functions and/or macros.

 

 

Return value

 

Value

Meaning

 

 

Negative value

An error occurred, check the LastError property value in order to get the error code

enumErrorCodes.ERR_NOERROR (0)

The method call was successful