From 078a7514630e39a0213c0b762a7d9bc34b0c787d Mon Sep 17 00:00:00 2001 From: Holger Wirtz Date: Sat, 29 Feb 2020 16:00:43 +0100 Subject: [PATCH] Fixing Transpose and Panorama. --- UI.hpp | 7 ++++--- config.h | 4 ++-- dexed.cpp | 3 ++- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/UI.hpp b/UI.hpp index 046b597..eb12932 100644 --- a/UI.hpp +++ b/UI.hpp @@ -1624,12 +1624,12 @@ void UI_func_transpose(uint8_t param) } } - MicroDexed[instance_id]->notesOff(); MicroDexed[instance_id]->data[DEXED_VOICE_OFFSET + DEXED_TRANSPOSE] = configuration.dexed[instance_id].transpose; + MicroDexed[instance_id]->notesOff(); } lcd.setCursor(0, 1); - lcd_display_int(configuration.dexed[instance_id].transpose, 2, true, true, false); + lcd_display_int(configuration.dexed[instance_id].transpose-24, 1, false, true, true); } if (LCDML.FUNC_close()) // ****** STABLE END ********* @@ -1810,6 +1810,7 @@ void UI_func_panorama(uint8_t param) { lcd.setCursor(0, 1); lcd.print(F("MONO-disabled")); + return; } } @@ -1837,7 +1838,7 @@ void UI_func_panorama(uint8_t param) if (configuration.mono == 0) { lcd.setCursor(0, 1); - lcd_display_int(configuration.dexed[instance_id].pan - 20, 2, false, true, true); + lcd_display_int(configuration.dexed[instance_id].pan - 20, 1, false, true, true); mono2stereo[instance_id]->panorama(mapfloat(configuration.dexed[instance_id].pan, PANORAMA_MIN, PANORAMA_MAX, -1.0, 1.0)); } } diff --git a/config.h b/config.h index a460df7..d5bfc44 100644 --- a/config.h +++ b/config.h @@ -177,7 +177,7 @@ #endif // Encoder with button -#define ENCODER_USE_INTERRUPTS +//#define ENCODER_USE_INTERRUPTS #define NUM_ENCODER 2 #define ENC_L_PIN_A 3 #define ENC_L_PIN_B 2 @@ -373,7 +373,7 @@ enum { DEXED, CHORUS, DELAY, REVERB}; #define MONOPOLY_MIN 0 #define MONOPOLY_MAX 1 -#define MONOPOLY_DEFAULT 1 +#define MONOPOLY_DEFAULT 0 #define PB_RANGE_MIN 0 #define PB_RANGE_MAX 12 diff --git a/dexed.cpp b/dexed.cpp index 367101c..d9e0c21 100644 --- a/dexed.cpp +++ b/dexed.cpp @@ -394,8 +394,9 @@ void Dexed::resetControllers(void) void Dexed::notesOff(void) { for (uint8_t i = 0; i < MAX_ACTIVE_NOTES; i++) { - if (voices[i].live == true && voices[i].keydown == true) { + if (voices[i].live == true) { voices[i].keydown = false; + voices[i].live = false; } } }