|
|
@ -85,9 +85,7 @@ AudioSynthWaveform ep_chorus_modulator; |
|
|
|
#if MOD_FILTER_OUTPUT != MOD_NO_FILTER_OUTPUT |
|
|
|
#if MOD_FILTER_OUTPUT != MOD_NO_FILTER_OUTPUT |
|
|
|
AudioFilterBiquad ep_modchorus_filter; |
|
|
|
AudioFilterBiquad ep_modchorus_filter; |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
AudioEffectModulatedDelay ep_modchorus_r; |
|
|
|
AudioEffectModulatedDelayStereo ep_modchorus; |
|
|
|
AudioEffectModulatedDelay ep_modchorus_l; |
|
|
|
|
|
|
|
AudioAmplifier ep_chorus_inverter; |
|
|
|
|
|
|
|
AudioMixer<2> ep_chorus_mixer_r; |
|
|
|
AudioMixer<2> ep_chorus_mixer_r; |
|
|
|
AudioMixer<2> ep_chorus_mixer_l; |
|
|
|
AudioMixer<2> ep_chorus_mixer_l; |
|
|
|
#endif |
|
|
|
#endif |
|
|
@ -254,19 +252,16 @@ AudioConnection patchCord[] = { |
|
|
|
#if defined(USE_FX) |
|
|
|
#if defined(USE_FX) |
|
|
|
{ep_stereo_panorama, 0, ep_chorus_mixer_r, 0}, |
|
|
|
{ep_stereo_panorama, 0, ep_chorus_mixer_r, 0}, |
|
|
|
{ep_stereo_panorama, 1, ep_chorus_mixer_l, 0}, |
|
|
|
{ep_stereo_panorama, 1, ep_chorus_mixer_l, 0}, |
|
|
|
{ep_stereo_panorama, 0, ep_modchorus_r, 0}, |
|
|
|
{ep_stereo_panorama, 0, ep_modchorus, 0}, |
|
|
|
{ep_stereo_panorama, 1, ep_modchorus_l, 0}, |
|
|
|
{ep_stereo_panorama, 1, ep_modchorus, 1}, |
|
|
|
#if MOD_FILTER_OUTPUT != MOD_NO_FILTER_OUTPUT |
|
|
|
#if MOD_FILTER_OUTPUT != MOD_NO_FILTER_OUTPUT |
|
|
|
{ep_chorus_modulator, 0, ep_modchorus_filter, 0}, |
|
|
|
{ep_chorus_modulator, 0, ep_modchorus_filter, 0}, |
|
|
|
{ep_modchorus_filter, 0, ep_modchorus_r, 1}, |
|
|
|
{ep_modchorus_filter, 0, ep_modchorus, 2}, |
|
|
|
{ep_modchorus_filter, 0, ep_chorus_inverter, 0}, |
|
|
|
|
|
|
|
#else |
|
|
|
#else |
|
|
|
{ep_chorus_modulator, 0, ep_modchorus_r, 1}, |
|
|
|
{ep_chorus_modulator, 0, ep_modchorus, 2}, |
|
|
|
{ep_chorus_modulator, 0, ep_chorus_inverter, 0}, |
|
|
|
|
|
|
|
#endif |
|
|
|
#endif |
|
|
|
{ep_chorus_inverter, 0, ep_modchorus_l, 1}, |
|
|
|
{ep_modchorus, 0, ep_chorus_mixer_r, 1}, |
|
|
|
{ep_modchorus_r, 0, ep_chorus_mixer_r, 1}, |
|
|
|
{ep_modchorus, 1, ep_chorus_mixer_l, 1}, |
|
|
|
{ep_modchorus_l, 0, ep_chorus_mixer_l, 1}, |
|
|
|
|
|
|
|
{ep_chorus_mixer_r, 0, reverb_mixer_r, REVERB_MIX_CH_EPIANO}, |
|
|
|
{ep_chorus_mixer_r, 0, reverb_mixer_r, REVERB_MIX_CH_EPIANO}, |
|
|
|
{ep_chorus_mixer_l, 0, reverb_mixer_l, REVERB_MIX_CH_EPIANO}, |
|
|
|
{ep_chorus_mixer_l, 0, reverb_mixer_l, REVERB_MIX_CH_EPIANO}, |
|
|
|
{ep_stereo_panorama, 0, master_mixer_r, MASTER_MIX_CH_EPIANO}, |
|
|
|
{ep_stereo_panorama, 0, master_mixer_r, MASTER_MIX_CH_EPIANO}, |
|
|
@ -588,41 +583,26 @@ void setup() |
|
|
|
#if defined(USE_EPIANO) |
|
|
|
#if defined(USE_EPIANO) |
|
|
|
// EP_CHORUS
|
|
|
|
// EP_CHORUS
|
|
|
|
ep_delayline_r = (int16_t*)malloc(MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
ep_delayline_r = (int16_t*)malloc(MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
if (ep_delayline_r != NULL) |
|
|
|
if (ep_delayline_r == NULL) |
|
|
|
{ |
|
|
|
|
|
|
|
memset(ep_delayline_r, 0, MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
|
|
|
|
if (!ep_modchorus_r.begin(ep_delayline_r, MOD_DELAY_SAMPLE_BUFFER)) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
#ifdef DEBUG |
|
|
|
|
|
|
|
Serial.println(F("AudioEffectModulatedDelay R - begin failed EP")); |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
while (1); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else |
|
|
|
|
|
|
|
{ |
|
|
|
{ |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("AudioEffectModulatedDelay R - memory allocation failed EP")); |
|
|
|
Serial.println(F("AudioEffectModulatedDelay R - memory allocation failed EP")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
while (1); |
|
|
|
while (1); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
ep_delayline_l = (int16_t*)malloc(MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
ep_delayline_l = (int16_t*)malloc(MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
if (ep_delayline_l != NULL) |
|
|
|
if (ep_delayline_l == NULL) |
|
|
|
{ |
|
|
|
|
|
|
|
memset(ep_delayline_l, 0, MOD_DELAY_SAMPLE_BUFFER * sizeof(int16_t)); |
|
|
|
|
|
|
|
if (!ep_modchorus_l.begin(ep_delayline_l, MOD_DELAY_SAMPLE_BUFFER)) |
|
|
|
|
|
|
|
{ |
|
|
|
{ |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("AudioEffectModulatedDelay L - begin failed EP")); |
|
|
|
Serial.println(F("AudioEffectModulatedDelay L - memory allocation failed EP")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
while (1); |
|
|
|
while (1); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
else |
|
|
|
if (!ep_modchorus.begin(ep_delayline_r, ep_delayline_l, MOD_DELAY_SAMPLE_BUFFER)) |
|
|
|
{ |
|
|
|
{ |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("AudioEffectModulatedDelay L - memory allocation failed EP")); |
|
|
|
Serial.println(F("AudioEffectModulatedDelayStereo - begin failed EP")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
while (1); |
|
|
|
while (1); |
|
|
|
} |
|
|
|
} |
|
|
@ -641,7 +621,6 @@ void setup() |
|
|
|
ep_chorus_mixer_l.gain(0, 1.0); |
|
|
|
ep_chorus_mixer_l.gain(0, 1.0); |
|
|
|
ep_chorus_mixer_r.gain(1, mapfloat(EP_CHORUS_LEVEL_DEFAULT, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_r.gain(1, mapfloat(EP_CHORUS_LEVEL_DEFAULT, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_l.gain(1, mapfloat(EP_CHORUS_LEVEL_DEFAULT, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_l.gain(1, mapfloat(EP_CHORUS_LEVEL_DEFAULT, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_inverter.gain(-1.0); |
|
|
|
|
|
|
|
ep_stereo_panorama.panorama(mapfloat(EP_PANORAMA_DEFAULT, EP_PANORAMA_MIN, EP_PANORAMA_MAX, -1.0, 1.0)); |
|
|
|
ep_stereo_panorama.panorama(mapfloat(EP_PANORAMA_DEFAULT, EP_PANORAMA_MIN, EP_PANORAMA_MAX, -1.0, 1.0)); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
@ -797,6 +776,8 @@ void setup() |
|
|
|
Serial.println(F("<setup end>")); |
|
|
|
Serial.println(F("<setup end>")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ep_modchorus.set_bypass(true); |
|
|
|
|
|
|
|
|
|
|
|
strcpy(seq.seq_name, "INIT Perf"); |
|
|
|
strcpy(seq.seq_name, "INIT Perf"); |
|
|
|
LCDML.OTHER_jumpToFunc(UI_func_voice_select); |
|
|
|
LCDML.OTHER_jumpToFunc(UI_func_voice_select); |
|
|
|
} |
|
|
|
} |
|
|
@ -2608,7 +2589,6 @@ void set_fx_params(void) |
|
|
|
ep_chorus_mixer_l.gain(0, 1.0); |
|
|
|
ep_chorus_mixer_l.gain(0, 1.0); |
|
|
|
ep_chorus_mixer_r.gain(1, mapfloat(configuration.fx.ep_chorus_level, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_r.gain(1, mapfloat(configuration.fx.ep_chorus_level, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_l.gain(1, mapfloat(configuration.fx.ep_chorus_level, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_mixer_l.gain(1, mapfloat(configuration.fx.ep_chorus_level, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_inverter.gain(-1.0); |
|
|
|
|
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|