Bugfix for setting delay level.

Fix pseudo-log curve.
pull/32/head
Holger Wirtz 4 years ago
parent fbb3267207
commit 978f876ab5
  1. 2
      MicroDexed.ino
  2. 5
      UI.hpp
  3. 4
      config.h

@ -1860,7 +1860,7 @@ float pseudo_log_curve(float value)
//return (mapfloat(_pseudo_log * arm_sin_f32(value), 0.0, _pseudo_log * arm_sin_f32(1.0), 0.0, 1.0));
//return (1 - sqrt(1 - value * value));
//return (pow(2, value) - 1);
return (pow(value, 2.5));
return (pow(value, 2.2));
}
uint32_t crc32(byte * calc_start, uint16_t calc_bytes) // base code from https://www.arduino.cc/en/Tutorial/EEPROMCrc

@ -1361,10 +1361,11 @@ void UI_func_delay_level(uint8_t param)
lcd_display_bar_int("Delay Lvl.", configuration.fx.delay_level[selected_instance_id], 1.0, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 3, false, false, false);
if (configuration.fx.delay_level[selected_instance_id] <= DELAY_LEVEL_MIN)
/*if (configuration.fx.delay_level[selected_instance_id] <= DELAY_LEVEL_MIN)
delay_fx[selected_instance_id]->disable(0);
else
delay_fx[selected_instance_id]->delay(0, constrain(configuration.fx.delay_time[selected_instance_id], DELAY_TIME_MIN, DELAY_TIME_MAX) * 10);
delay_fx[selected_instance_id]->delay(0, constrain(configuration.fx.delay_time[selected_instance_id], DELAY_TIME_MIN, DELAY_TIME_MAX) * 10); */
delay_mixer[selected_instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_level[selected_instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0)));
}
if (LCDML.FUNC_close()) // ****** STABLE END *********

@ -56,7 +56,7 @@
// sed -i.orig 's/^#define USB_MIDI_SYSEX_MAX 290/#define USB_MIDI_SYSEX_MAX 4104/' /usr/local/arduino-teensy/hardware/teensy/avr/cores/teensy3/usb_midi.h
//#define USB_MIDI_SYSEX_MAX 4104
#define VERSION "1.0.4"
#define VERSION "1.0.5"
//*************************************************************************************************
//* DEVICE SETTINGS
@ -112,7 +112,7 @@
#define MOD_FILTER_OUTPUT MOD_BUTTERWORTH_FILTER_OUTPUT // MOD_LINKWITZ_RILEY_FILTER_OUTPUT MOD_BUTTERWORTH_FILTER_OUTPUT MOD_NO_FILTER_OUTPUT
#define MOD_FILTER_CUTOFF_HZ 2000
// REVERB parameters
//#define REVERB_ANTIALIAS_FRQ 7500
#define REVERB_ANTIALIAS_FRQ 7500
// SGTL5000
#ifdef TEENSY_AUDIO_BOARD
#define SGTL5000_AUDIO_ENHANCE 1

Loading…
Cancel
Save