Update MIDI.hpp
This commit is contained in:
parent
2ffbdef8da
commit
f905cba68c
39
src/MIDI.hpp
39
src/MIDI.hpp
|
|
@ -911,24 +911,33 @@ bool MidiInterface<SerialPort, Settings>::parse()
|
|||
mMessage.valid = true;
|
||||
|
||||
// Activate running status (if enabled for the received type)
|
||||
switch (mMessage.type)
|
||||
{
|
||||
case NoteOff:
|
||||
case NoteOn:
|
||||
case AfterTouchPoly:
|
||||
case ControlChange:
|
||||
case ProgramChange:
|
||||
case AfterTouchChannel:
|
||||
case PitchBend:
|
||||
// Running status enabled: store it from received message
|
||||
mRunningStatus_RX = mPendingMessage[0];
|
||||
break;
|
||||
if (Settings::UseRunningStatus) {
|
||||
|
||||
default:
|
||||
switch (mMessage.type)
|
||||
{
|
||||
case NoteOff:
|
||||
case NoteOn:
|
||||
case AfterTouchPoly:
|
||||
case ControlChange:
|
||||
case ProgramChange:
|
||||
case AfterTouchChannel:
|
||||
case PitchBend:
|
||||
// Running status enabled: store it from received message
|
||||
mRunningStatus_RX = mPendingMessage[0];
|
||||
break;
|
||||
|
||||
default:
|
||||
// No running status
|
||||
mRunningStatus_RX = InvalidType;
|
||||
break;
|
||||
mRunningStatus_RX = InvalidType;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
else {
|
||||
|
||||
mRunningStatus_RX = InvalidType;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in New Issue