FastLED 3.9.15
Loading...
Searching...
No Matches

◆ inputFilter()

template<class Transport, class Settings, class Platform>
bool MidiInterface< Transport, Settings, Platform >::inputFilter ( Channel inChannel)
inlineprivate

Definition at line 1091 of file MIDI.hpp.

1092{
1093 // This method handles recognition of channel
1094 // (to know if the message is destinated to the Arduino)
1095
1096 // First, check if the received message is Channel
1097 if (mMessage.type >= NoteOff && mMessage.type <= PitchBend)
1098 {
1099 // Then we need to know if we listen to it
1100 if ((mMessage.channel == inChannel) ||
1102 {
1103 return true;
1104 }
1105 else
1106 {
1107 // We don't listen to this channel
1108 return false;
1109 }
1110 }
1111 else
1112 {
1113 // System messages are always received
1114 return true;
1115 }
1116}
MidiMessage mMessage
Definition MIDI.h:283
The main class for MIDI handling. It is templated over the type of serial port to provide abstraction...
Definition MIDI.h:55

References MIDI_CHANNEL_OMNI, mMessage, NoteOff, and PitchBend.

Referenced by read().

+ Here is the caller graph for this function: