Send CC 0 on release (MIDI Learn fix); flash_latency=0

This commit is contained in:
ash
2026-07-03 22:32:24 +00:00
parent dfa339a9b9
commit 33c9dd10c0
2 changed files with 2 additions and 5 deletions
+1 -4
View File
@@ -144,10 +144,7 @@ void AppTask::process_switch_event(uint8_t switch_id, bool pressed) {
uint8_t cc_num = cc_map[i]; uint8_t cc_num = cc_map[i];
// Use palette index 127 (magenta) for visible feedback // Use palette index 127 (magenta) for visible feedback
uint8_t value = pressed ? 127 : 0; uint8_t value = pressed ? 127 : 0;
midi_transport->send_cc(channel, cc_num, value);
if (pressed) {
midi_transport->send_cc(channel, cc_num, value);
}
break; break;
} }
} }
+1 -1
View File
@@ -21,7 +21,7 @@ UsbMidiTransport midi_transport;
AppTask controller(&led_driver, &switch_driver, &midi_transport); AppTask controller(&led_driver, &switch_driver, &midi_transport);
ExpressionPedal exp_pedal(4); ExpressionPedal exp_pedal(4);
volatile uint32_t flash_latency = 55; // ms delay to compensate for Loopy Pro rendering volatile uint32_t flash_latency = 0;
volatile uint8_t beats_per_bar = 4; // change to match your project's time signature volatile uint8_t beats_per_bar = 4; // change to match your project's time signature
TaskHandle_t midi_task_handle = NULL; TaskHandle_t midi_task_handle = NULL;