Merge pull request #124 from insolace/master
::send ignores realtime messages, quick fix
This commit is contained in:
commit
2ffbdef8da
|
|
@ -134,6 +134,8 @@ void MidiInterface<SerialPort, Settings>::send(MidiType inType,
|
||||||
DataByte inData1,
|
DataByte inData1,
|
||||||
DataByte inData2,
|
DataByte inData2,
|
||||||
Channel inChannel)
|
Channel inChannel)
|
||||||
|
{
|
||||||
|
if (inType <= PitchBend) // Channel messages
|
||||||
{
|
{
|
||||||
// Then test if channel is valid
|
// Then test if channel is valid
|
||||||
if (inChannel >= MIDI_CHANNEL_OFF ||
|
if (inChannel >= MIDI_CHANNEL_OFF ||
|
||||||
|
|
@ -142,9 +144,6 @@ void MidiInterface<SerialPort, Settings>::send(MidiType inType,
|
||||||
{
|
{
|
||||||
return; // Don't send anything
|
return; // Don't send anything
|
||||||
}
|
}
|
||||||
|
|
||||||
if (inType <= PitchBend) // Channel messages
|
|
||||||
{
|
|
||||||
// Protection: remove MSBs on data
|
// Protection: remove MSBs on data
|
||||||
inData1 &= 0x7f;
|
inData1 &= 0x7f;
|
||||||
inData2 &= 0x7f;
|
inData2 &= 0x7f;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue