From be225366b3c0458dd34691717430411335a3411e Mon Sep 17 00:00:00 2001 From: Dirk Niggemann Date: Tue, 29 Oct 2019 12:26:40 +0000 Subject: [PATCH] Removed incorrect patchcord for FreeVerbStereo --- MicroDexed.ino | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/MicroDexed.ino b/MicroDexed.ino index 4d024e6..bfd4776 100644 --- a/MicroDexed.ino +++ b/MicroDexed.ino @@ -129,8 +129,11 @@ void create_audio_connections(AudioSourceMicroDexed &d) dynamicConnections[nDynamic++] = new AudioConnection(d, 0 , master_mixer_l, 0); #if defined(USE_REVERB) dynamicConnections[nDynamic++] = new AudioConnection(d, 0, freeverbs1, 0); - dynamicConnections[nDynamic++] = new AudioConnection(d, 0, freeverbs1, 1); #endif + for (int i = 0; i < nDynamic; i++) { + if (dynamicConnections[i] == NULL) + Serial.printf ("Bad connection %d\n", i); + } } bool sd_card_available = false; @@ -161,7 +164,7 @@ config_t configuration; bool eeprom_update_flag = false; // Allocate the delay lines for chorus -short delayline[MOD_DELAY_SAMPLE_BUFFER]; +int16_t delayline[MOD_DELAY_SAMPLE_BUFFER]; #ifdef ENABLE_LCD_UI /*********************************************************************** @@ -210,6 +213,9 @@ void setup() Serial.print(F("Creating MicroDexed engine ")); Serial.println(i, DEC); MicroDexed[i] = new AudioSourceMicroDexed(SAMPLE_RATE); + if (MicroDexed[i] == NULL) { + Serial.print(F("Unable to create MicroDexed engine!")); + } create_audio_connections(*MicroDexed[i]); } @@ -313,7 +319,7 @@ void setup() change_disp_sd(true); #endif // Init effects - memset(delayline, 0, MOD_DELAY_SAMPLE_BUFFER); + memset(delayline, 0, sizeof(delayline)); if (!modchorus.begin(delayline, MOD_DELAY_SAMPLE_BUFFER)) { Serial.println(F("AudioEffectModulatedDelay - begin failed")); while (1);