Fix for peak detection.

Reduced max notes to 12 for T_3.6 with FX.
pull/32/head
Holger Wirtz 5 years ago
parent a0870ae23b
commit 7c7ba7ac0b
  1. 8
      MicroDexed.ino
  2. 2
      config.h

@ -270,7 +270,7 @@ void setup()
#ifdef DEBUG #ifdef DEBUG
char version_string[LCD_cols + 1]; char version_string[LCD_cols + 1];
generate_version_string(version_string, sizeof(version_string)); generate_version_string(version_string, sizeof(version_string));
Serial.println(F("MicroDexed based on https://github.com/asb2m10/dexed")); Serial.println(F("MicroDexed based on https://github.com/asb2m10/dexed"));
Serial.println(F("(c)2018-2020 H. Wirtz <wirtz@parasitstudio.de>")); Serial.println(F("(c)2018-2020 H. Wirtz <wirtz@parasitstudio.de>"));
Serial.println(F("https://codeberg.org/dcoredump/MicroDexed")); Serial.println(F("https://codeberg.org/dcoredump/MicroDexed"));
@ -672,10 +672,10 @@ void loop()
if (cpu_mem_millis >= SHOW_CPU_LOAD_MSEC) if (cpu_mem_millis >= SHOW_CPU_LOAD_MSEC)
{ {
if (master_peak_r.available()) if (master_peak_r.available())
if (master_peak_r.read() > 0.99) if (master_peak_r.read() == 1.0)
peak_r++; peak_r++;
if (master_peak_l.available()) if (master_peak_l.available())
if (master_peak_l.read() > 0.99) if (master_peak_l.read() == 1.0)
peak_l++; peak_l++;
if (microdexed_peak.available()) if (microdexed_peak.available())
{ {
@ -1592,12 +1592,12 @@ void generate_version_string(char* buffer, uint8_t len)
itoa (MAX_NOTES, tmp, 10); itoa (MAX_NOTES, tmp, 10);
strncat(buffer, tmp, 2); strncat(buffer, tmp, 2);
#endif #endif
buffer[len] = '\0';
} }
/****************************************************************************** /******************************************************************************
DEBUG HELPER DEBUG HELPER
******************************************************************************/ ******************************************************************************/
#if defined (DEBUG) && defined (SHOW_CPU_LOAD_MSEC) #if defined (DEBUG) && defined (SHOW_CPU_LOAD_MSEC)
void show_cpu_and_mem_usage(void) void show_cpu_and_mem_usage(void)
{ {

@ -252,7 +252,7 @@ enum { DEXED, CHORUS, DELAY, REVERB};
// Teensy-3.6 settings // Teensy-3.6 settings
#define MIDI_DEVICE_USB_HOST 1 #define MIDI_DEVICE_USB_HOST 1
#if defined(USE_FX) #if defined(USE_FX)
#define MAX_NOTES 13 #define MAX_NOTES 12
#else #else
#define MAX_NOTES 16 #define MAX_NOTES 16
#endif #endif

Loading…
Cancel
Save