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

◆ HandleControlChange()

void KeyboardState::HandleControlChange ( uint8_t d1,
uint8_t d2 )

Definition at line 167 of file Keyboard.cpp.

167 {
168 // Note that d1 and d2 just mean "data-1" and "data-2".
169 // TODO: Find out what d1 and d2 should be called.
170 const bool foot_pedal = (d1 == kMidiFootPedal);
171
172 if (foot_pedal) {
173 // Spec says that if that values 0-63 are OFF, otherwise ON.
174 sustain_pedal_ = (d2 >= 64);
175 }
176}
bool sustain_pedal_
Definition Keyboard.h:102
@ kMidiFootPedal
Definition settings.h:22

References kMidiFootPedal, and sustain_pedal_.