diff --git a/include/led_stub.h b/include/led_stub.h index f76e407..f45cd6b 100644 --- a/include/led_stub.h +++ b/include/led_stub.h @@ -11,9 +11,6 @@ public: virtual void clear_all() = 0; virtual void set_led_brightness(uint8_t brightness) = 0; virtual void flash_activity() {} - virtual void flash_sysex() {} - virtual void flash_all(uint8_t r, uint8_t g, uint8_t b, uint16_t duration) {} - virtual void flash_one(uint8_t index, uint8_t r, uint8_t g, uint8_t b, uint16_t duration) {} virtual void update() {} virtual uint8_t note_to_index(uint8_t note) { @@ -50,9 +47,6 @@ public: void clear_all() override; void set_led_brightness(uint8_t brightness) override; void flash_activity() override; - void flash_sysex() override; - void flash_all(uint8_t r, uint8_t g, uint8_t b, uint16_t duration) override; - void flash_one(uint8_t index, uint8_t r, uint8_t g, uint8_t b, uint16_t duration) override; void update() override; void set_mux(PixelStompMux* mux); diff --git a/src/app_task.cpp b/src/app_task.cpp index be0c1d1..dacab2d 100644 --- a/src/app_task.cpp +++ b/src/app_task.cpp @@ -46,22 +46,8 @@ void AppTask::process_midi_event(const MidiEvent& event) { Serial.printf("[APP] MIDI IN: Type=%d Ch=%d Data1=%d Data2=%d\n", event.type, event.channel, event.data1, event.data2); - // Visual MIDI type indicator (works without serial on iPad) - if (event.type == MidiEvent::SYSEX) { - led_driver->flash_all(255, 255, 255, 200); // SysEx = ALL white - } else if (event.type == MidiEvent::NOTE_ON || event.type == MidiEvent::NOTE_OFF) { - led_driver->flash_one(0, 255, 0, 0, 100); // Note = LED 0 red - } else if (event.type == MidiEvent::CONTROL_CHANGE) { - led_driver->flash_one(1, 0, 255, 0, 100); // CC = LED 1 green - - // Generic mode: Loopy Pro mirrors back on same CC with state value - // Visualize the velocity/CC value on LED 2-3 - uint8_t val = event.data2; - if (val < 32) led_driver->flash_one(2, 255, 0, 0, 100); // 0-31 = red (recording?) - else if (val < 64) led_driver->flash_one(2, 255, 128, 0, 100); // 32-63 = amber (queued?) - else if (val < 96) led_driver->flash_one(2, 0, 255, 0, 100); // 64-95 = green (playing?) - else led_driver->flash_one(2, 0, 0, 255, 100); // 96-127 = blue (other?) - } + // Flash LED 0 white briefly on ANY MIDI input - visual activity indicator + led_driver->flash_activity(); if (event.type == MidiEvent::SYSEX) { // Cin is encoded in channel for SYSEX packets diff --git a/src/midi_transport.cpp b/src/midi_transport.cpp index 1eda5ec..cb26a25 100644 --- a/src/midi_transport.cpp +++ b/src/midi_transport.cpp @@ -13,9 +13,9 @@ UsbMidiTransport::~UsbMidiTransport() { bool UsbMidiTransport::begin() { Serial.println("[MIDI] Setting up USB MIDI device..."); - TinyUSBDevice.setManufacturerDescriptor("Novation"); - TinyUSBDevice.setProductDescriptor("Launchpad X"); - TinyUSBDevice.setSerialDescriptor("LPX00001"); + TinyUSBDevice.setManufacturerDescriptor("JOC"); + TinyUSBDevice.setProductDescriptor("JOC Midi"); + TinyUSBDevice.setSerialDescriptor("JOCMIDI001"); TinyUSBDevice.begin(0); if (!usb_midi.begin()) {