|
|
@ -359,7 +359,7 @@ void create_audio_drum_chain(uint8_t instance_id) |
|
|
|
uint8_t sd_card = 0; |
|
|
|
uint8_t sd_card = 0; |
|
|
|
Sd2Card card; |
|
|
|
Sd2Card card; |
|
|
|
SdVolume volume; |
|
|
|
SdVolume volume; |
|
|
|
float midi_ticks_factor[10] = {0.0, 0.25, 0.375, 0.5, 0.75, 1.0, 1.5, 2.0, 3.0 , 4.0}; |
|
|
|
const float midi_ticks_factor[10] = {0.0, 0.25, 0.375, 0.5, 0.75, 1.0, 1.5, 2.0, 3.0 , 4.0}; |
|
|
|
uint8_t midi_bpm_counter = 0; |
|
|
|
uint8_t midi_bpm_counter = 0; |
|
|
|
uint8_t midi_bpm = 0; |
|
|
|
uint8_t midi_bpm = 0; |
|
|
|
int16_t _midi_bpm = -1; |
|
|
|
int16_t _midi_bpm = -1; |
|
|
@ -565,7 +565,7 @@ void setup() |
|
|
|
} |
|
|
|
} |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
//Setup (PROGMEM-) sample drums
|
|
|
|
// Setup (PROGMEM) sample drums
|
|
|
|
#if NUM_DRUMS > 0 |
|
|
|
#if NUM_DRUMS > 0 |
|
|
|
// create dynamic Drum instances
|
|
|
|
// create dynamic Drum instances
|
|
|
|
for (uint8_t instance_id = 0; instance_id < NUM_DRUMS; instance_id++) |
|
|
|
for (uint8_t instance_id = 0; instance_id < NUM_DRUMS; instance_id++) |
|
|
@ -618,10 +618,10 @@ void setup() |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
ep_chorus_mixer_r.gain(0, 1.0); |
|
|
|
ep_chorus_mixer_r.gain(0, 1.0); |
|
|
|
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(EP_CHORUS_LEVEL_DEFAULT, 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(EP_CHORUS_LEVEL_DEFAULT, EP_CHORUS_LEVEL_MIN, EP_CHORUS_LEVEL_MAX, 0.0, 0.5)); |
|
|
|
ep_chorus_inverter.gain(-1.0); |
|
|
|
ep_chorus_inverter.gain(-1.0); |
|
|
|
ep_stereo_panorama.panorama(0.0); |
|
|
|
ep_stereo_panorama.panorama(mapfloat(EP_PANORAMA_DEFAULT, EP_PANORAMA_DEFAULT, EP_PANORAMA_DEFAULT, 0.0, 1.0)); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
@ -2256,7 +2256,6 @@ void check_configuration_epiano(void) |
|
|
|
configuration.epiano.detune = constrain(configuration.epiano.detune, EP_DETUNE_MIN, EP_DETUNE_MAX); |
|
|
|
configuration.epiano.detune = constrain(configuration.epiano.detune, EP_DETUNE_MIN, EP_DETUNE_MAX); |
|
|
|
configuration.epiano.overdrive = constrain(configuration.epiano.overdrive, EP_OVERDRIVE_MIN, EP_OVERDRIVE_MAX); |
|
|
|
configuration.epiano.overdrive = constrain(configuration.epiano.overdrive, EP_OVERDRIVE_MIN, EP_OVERDRIVE_MAX); |
|
|
|
configuration.epiano.lowest_note = constrain(configuration.epiano.lowest_note, EP_LOWEST_NOTE_MIN, EP_LOWEST_NOTE_MAX); |
|
|
|
configuration.epiano.lowest_note = constrain(configuration.epiano.lowest_note, EP_LOWEST_NOTE_MIN, EP_LOWEST_NOTE_MAX); |
|
|
|
configuration.epiano.highest_note = 108; // TODO!
|
|
|
|
|
|
|
|
configuration.epiano.highest_note = constrain(configuration.epiano.highest_note, EP_HIGHEST_NOTE_MIN, EP_HIGHEST_NOTE_MAX); |
|
|
|
configuration.epiano.highest_note = constrain(configuration.epiano.highest_note, EP_HIGHEST_NOTE_MIN, EP_HIGHEST_NOTE_MAX); |
|
|
|
configuration.epiano.transpose = constrain(configuration.epiano.transpose, EP_TRANSPOSE_MIN, EP_TRANSPOSE_MAX); |
|
|
|
configuration.epiano.transpose = constrain(configuration.epiano.transpose, EP_TRANSPOSE_MIN, EP_TRANSPOSE_MAX); |
|
|
|
configuration.epiano.sound_intensity = constrain(configuration.epiano.sound_intensity, EP_SOUND_INTENSITY_MIN, EP_SOUND_INTENSITY_MAX); |
|
|
|
configuration.epiano.sound_intensity = constrain(configuration.epiano.sound_intensity, EP_SOUND_INTENSITY_MIN, EP_SOUND_INTENSITY_MAX); |
|
|
@ -2508,6 +2507,7 @@ void set_fx_params(void) |
|
|
|
uint16_t midi_sync_delay_time = uint16_t(60000.0 * midi_ticks_factor[configuration.fx.delay_sync[instance_id]] / seq.seq_bpm); |
|
|
|
uint16_t midi_sync_delay_time = uint16_t(60000.0 * midi_ticks_factor[configuration.fx.delay_sync[instance_id]] / seq.seq_bpm); |
|
|
|
delay_fx[instance_id]->delay(0, constrain(midi_sync_delay_time, DELAY_TIME_MIN, DELAY_TIME_MAX * 10)); |
|
|
|
delay_fx[instance_id]->delay(0, constrain(midi_sync_delay_time, DELAY_TIME_MIN, DELAY_TIME_MAX * 10)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// REVERB SEND
|
|
|
|
// REVERB SEND
|
|
|
|
reverb_mixer_r.gain(instance_id, volume_transform(mapfloat(configuration.fx.reverb_send[instance_id], REVERB_SEND_MIN, REVERB_SEND_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
|
reverb_mixer_r.gain(instance_id, volume_transform(mapfloat(configuration.fx.reverb_send[instance_id], REVERB_SEND_MIN, REVERB_SEND_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
|
reverb_mixer_l.gain(instance_id, volume_transform(mapfloat(configuration.fx.reverb_send[instance_id], REVERB_SEND_MIN, REVERB_SEND_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
|
reverb_mixer_l.gain(instance_id, volume_transform(mapfloat(configuration.fx.reverb_send[instance_id], REVERB_SEND_MIN, REVERB_SEND_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
@ -2538,6 +2538,7 @@ void set_fx_params(void) |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#if defined(USE_EPIANO) |
|
|
|
#if defined(USE_EPIANO) |
|
|
|
|
|
|
|
#ifdef USE_FX |
|
|
|
reverb_mixer_r.gain(REVERB_MIX_CH_EPIANO, mapfloat(configuration.fx.ep_reverb_send, EP_REVERB_SEND_MIN, EP_REVERB_SEND_MAX, 0.0, 1.0)); // EPiano Reverb-Send
|
|
|
|
reverb_mixer_r.gain(REVERB_MIX_CH_EPIANO, mapfloat(configuration.fx.ep_reverb_send, EP_REVERB_SEND_MIN, EP_REVERB_SEND_MAX, 0.0, 1.0)); // EPiano Reverb-Send
|
|
|
|
reverb_mixer_l.gain(REVERB_MIX_CH_EPIANO, mapfloat(configuration.fx.ep_reverb_send, EP_REVERB_SEND_MIN, EP_REVERB_SEND_MAX, 0.0, 1.0)); // EPiano Reverb-Send
|
|
|
|
reverb_mixer_l.gain(REVERB_MIX_CH_EPIANO, mapfloat(configuration.fx.ep_reverb_send, EP_REVERB_SEND_MIN, EP_REVERB_SEND_MAX, 0.0, 1.0)); // EPiano Reverb-Send
|
|
|
|
|
|
|
|
|
|
|
@ -2573,6 +2574,7 @@ void set_fx_params(void) |
|
|
|
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); |
|
|
|
ep_chorus_inverter.gain(-1.0); |
|
|
|
|
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
master_mixer_r.gain(MASTER_MIX_CH_REVERB, volume_transform(mapfloat(configuration.fx.reverb_level, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
|
master_mixer_r.gain(MASTER_MIX_CH_REVERB, volume_transform(mapfloat(configuration.fx.reverb_level, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 0.0, VOL_MAX_FLOAT))); |
|
|
|