|
|
|
@ -113,6 +113,13 @@ AudioEffectFreeverbStereoFloat freeverb; |
|
|
|
|
#endif |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
#if defined(USE_EPIANO) |
|
|
|
|
AudioMixer<5> master_mixer_r; |
|
|
|
|
AudioMixer<5> master_mixer_l; |
|
|
|
|
#else |
|
|
|
|
AudioMixer<4> master_mixer_r; |
|
|
|
|
AudioMixer<4> master_mixer_l; |
|
|
|
|
#endif |
|
|
|
|
AudioAmplifier volume_r; |
|
|
|
|
AudioAmplifier volume_l; |
|
|
|
|
AudioEffectStereoMono stereo2mono; |
|
|
|
@ -275,8 +282,8 @@ AudioConnection patchCord[] = { |
|
|
|
|
{ep_delay_mixer_r, 0, reverb_mixer_r, 3}, |
|
|
|
|
{ep_delay_mixer_l, 0, reverb_mixer_l, 5}, |
|
|
|
|
#else |
|
|
|
|
{ep, 0, master_mixer_r, 3}, |
|
|
|
|
{ep, 1, master_mixer_l, 3}, , |
|
|
|
|
{ep, 0, master_mixer_r, 4}, |
|
|
|
|
{ep, 1, master_mixer_l, 4}, , |
|
|
|
|
#endif |
|
|
|
|
#endif |
|
|
|
|
}; |
|
|
|
@ -587,7 +594,7 @@ void setup() |
|
|
|
|
// Setup EPiano
|
|
|
|
|
#if defined(USE_FX) |
|
|
|
|
// EP_CHORUS
|
|
|
|
|
switch (configuration.fx.ep_chorus_waveform[instance_id]) |
|
|
|
|
switch (configuration.fx.ep_chorus_waveform) |
|
|
|
|
{ |
|
|
|
|
case 0: |
|
|
|
|
ep_chorus_modulator.begin(WAVEFORM_TRIANGLE); |
|
|
|
@ -599,26 +606,24 @@ void setup() |
|
|
|
|
ep_chorus_modulator.begin(WAVEFORM_TRIANGLE); |
|
|
|
|
} |
|
|
|
|
ep_chorus_modulator.phase(0); |
|
|
|
|
ep_chorus_modulator.frequency(configuration.fx.ep_chorus_frequency[i |
|
|
|
|
nstance_id] / 10.0); |
|
|
|
|
ep_chorus_modulator.frequency(configuration.fx.ep_chorus_frequency / 10.0); |
|
|
|
|
ep_chorus_modulator.amplitude(mapfloat(configuration.fx.ep_chorus_depth, EP_CHORUS_DEPTH_MIN, EP_CHORUS_DEPTH_MAX, 0.0, 1.0)); |
|
|
|
|
ep_chorus_modulator.offset(0.0); |
|
|
|
|
|
|
|
|
|
#if MOD_FILTER_OUTPUT == MOD_BUTTERWORTH_FILTER_OUTPUT |
|
|
|
|
// Butterworth filter, 12 db/octave
|
|
|
|
|
ep_modchorus_filter[instance_id]->setLowpass(0, MOD_FILTER_CUTOFF_HZ, 0.707); |
|
|
|
|
ep_modchorus_filter.setLowpass(0, MOD_FILTER_CUTOFF_HZ, 0.707); |
|
|
|
|
#elif MOD_FILTER_OUTPUT == MOD_LINKWITZ_RILEY_FILTER_OUTPUT |
|
|
|
|
// Linkwitz-Riley filter, 48 dB/octave
|
|
|
|
|
ep_modchorus_filter[instance_id]->setLowpass(0, MOD_FILTER_CUTOFF_HZ, 0.54); |
|
|
|
|
ep_modchorus_filter[instance_id]->setLowpass(1, MOD_FILTER_CUTOFF_HZ, 1.3); |
|
|
|
|
ep_modchorus_filter[instance_id]->setLowpass(2, MOD_FILTER_CUTOFF_HZ, 0.54); |
|
|
|
|
ep_modchorus_filter[instance_id]->setLowpass(3, MOD_FILTER_CUTOFF_HZ, 1.3); |
|
|
|
|
#endif |
|
|
|
|
ep_modchorus_filter.setLowpass(0, MOD_FILTER_CUTOFF_HZ, 0.54); |
|
|
|
|
ep_modchorus_filter.setLowpass(1, MOD_FILTER_CUTOFF_HZ, 1.3); |
|
|
|
|
ep_modchorus_filter.setLowpass(2, MOD_FILTER_CUTOFF_HZ, 0.54); |
|
|
|
|
ep_modchorus_filter.setLowpass(3, MOD_FILTER_CUTOFF_HZ, 1.3); |
|
|
|
|
#endif |
|
|
|
|
ep_chorus_mixer_r.gain(0, 1.0); |
|
|
|
|
ep_chorus_mixer_l.gain(0, 1.0); |
|
|
|
|
ep_chorus_mixer.gain(1, mapfloat(configuration.fx.ep_chorus_level, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
|
ep_chorus_mixer.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_inverter.gain(-1.0); |
|
|
|
|
ep_delay_mixer_r.gain(0, 1.0); |
|
|
|
|
ep_delay_mixer_l.gain(0, 1.0);; |
|
|
|
|