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

◆ HandleControlChange()

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

Definition at line 169 of file Keyboard.cpp.

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

References kMidiFootPedal, and sustain_pedal_.