Fix MIDI channel selection

This commit is contained in:
2025-07-01 20:00:36 +02:00
parent fa8c2f734d
commit cc95ee8aa5
2 changed files with 7 additions and 3 deletions
@@ -1,4 +1,4 @@
#define FW_VER 1.0
#define FW_VER 1.01
#define USE_OLED true // OLED displays
#define USE_ENCODER true
#define EEPROM_MIDI_CHANNEL_ADDR 0 // Address to save MIDI channel in EEPROM
@@ -133,7 +133,10 @@ void checkEncoder() {
if (newChannel != currentMidiChannel) {
currentMidiChannel = newChannel;
updateOLED();
MIDI.begin(currentMidiChannel); // Reset MIDI, begin on current channel
#if USE_OLED
updateOLED();
#endif
// Mark that channel changed and restart delay timer
lastChannelChangeTime = millis();
@@ -159,7 +162,7 @@ void setup() {
} else {
oled.clearDisplay();
oled.drawBitmap(0, 0, bootuplogo, BOOTLOGO_WIDTH, BOOTLOGO_HEIGHT, 1);
oled.setCursor(62, 18);
oled.setCursor(54, 18);
oled.setTextColor(SSD1306_WHITE);
oled.print("FW ver. " + String(FW_VER));
oled.display();