diff --git a/.swo b/.swo index 47f3149..3b274c1 100644 Binary files a/.swo and b/.swo differ diff --git a/MicroDexed.ino b/MicroDexed.ino index 508f403..0c539b8 100644 --- a/MicroDexed.ino +++ b/MicroDexed.ino @@ -425,8 +425,8 @@ void setup() master_mixer_r.gain(instance_id, 1.0); master_mixer_l.gain(instance_id, 1.0); } - master_mixer_r.gain(3, configuration.fx.reverb_level / 100.0); - master_mixer_l.gain(3, configuration.fx.reverb_level / 100.0); + master_mixer_r.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100, true)); + master_mixer_l.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100, true)); set_sys_params(); @@ -544,7 +544,7 @@ void loop() if (midi_decay_timer > MIDI_DECAY_TIMER && midi_voices[instance_id] > 0 && midi_playing[instance_id] == false) { midi_playing[instance_id] = true; - lcd.setCursor(14 + instance_id,1); + lcd.setCursor(14 + instance_id, 1); lcd.write(6 + instance_id); } else if (midi_decay_timer > MIDI_DECAY_TIMER && midi_voices[instance_id] == 0) @@ -714,7 +714,7 @@ void handleControlChange(byte inChannel, byte inCtrl, byte inValue) #ifdef USE_FX MicroDexed[instance_id]->fx.Gain = mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX); #else - dexed_level[instance_id]->gain(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX)); + dexed_level[instance_id]->gain(pseudo_log_curve(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX), true)); #endif if (LCDML.FUNC_getID() == LCDML.OTHER_getIDFromFunction(UI_func_sound_intensity)) { @@ -806,7 +806,7 @@ void handleControlChange(byte inChannel, byte inCtrl, byte inValue) break; case 107: // CC 107: delay volume configuration.fx.delay_level[instance_id] = map(inValue, 0, 0x7f, DELAY_SEND_MIN, DELAY_SEND_MAX); - delay_mixer[instance_id]->gain(1, mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0)); + delay_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0), true)); if (LCDML.FUNC_getID() == LCDML.OTHER_getIDFromFunction(UI_func_delay_level)) { LCDML.OTHER_updateFunc(); @@ -1451,22 +1451,22 @@ void initial_values_from_eeprom(bool init) //chorus_mixer[instance_id]->gain(0, 1.0 - pseudo_log_curve(mapfloat(configuration.fx.chorus_level[instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 1.0), true)); //chorus_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.chorus_level[instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 1.0), true)); //chorus_mixer[instance_id]->gain(0, 1.0 - mapfloat(configuration.fx.chorus_level[instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 0.5)); - chorus_mixer[instance_id]->gain(1, mapfloat(configuration.fx.chorus_level[instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 0.5)); + chorus_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.chorus_level[instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 0.5), true)); delay_mixer[instance_id]->gain(0, 1.0); - delay_mixer[instance_id]->gain(1, mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0)); + delay_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0), true)); delay_fb_mixer[instance_id]->gain(0, 1.0); - delay_fb_mixer[instance_id]->gain(1, mapfloat(configuration.fx.delay_feedback[instance_id], DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0)); + delay_fb_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_feedback[instance_id], DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0), true)); // MicroDexed[instance_id]->fx.Gain = configuration.dexed[instance_id].sound_intensity / 100.0; MicroDexed[instance_id]->fx.Gain = 1.0; MicroDexed[instance_id]->fx.Reso = mapfloat(configuration.dexed[instance_id].filter_resonance, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 1.0, 0.0); MicroDexed[instance_id]->fx.Cutoff = mapfloat(configuration.dexed[instance_id].filter_cutoff, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 1.0, 0.0); - reverb_mixer_r.gain(instance_id, configuration.fx.reverb_send[instance_id] / 100.0); - reverb_mixer_l.gain(instance_id, configuration.fx.reverb_send[instance_id] / 100.0); + reverb_mixer_r.gain(instance_id, pseudo_log_curve(configuration.fx.reverb_send[instance_id] / 100.0, true)); + reverb_mixer_l.gain(instance_id, pseudo_log_curve(configuration.fx.reverb_send[instance_id] / 100.0, true)); #endif - dexed_level[instance_id]->gain(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX)); + dexed_level[instance_id]->gain(pseudo_log_curve(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX), true)); set_voiceconfig_params(instance_id); } @@ -1789,14 +1789,14 @@ void set_fx_params(void) // DELAY delay_mixer[instance_id]->gain(0, 1.0); - delay_mixer[instance_id]->gain(1, mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0)); + delay_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_level[instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0), true)); delay_fx[instance_id]->delay(0, constrain(configuration.fx.delay_time[instance_id] * 10, DELAY_TIME_MIN * 10, DELAY_TIME_MAX * 10)); delay_fb_mixer[instance_id]->gain(0, 1.0); - delay_fb_mixer[instance_id]->gain(1, mapfloat(configuration.fx.delay_feedback[instance_id], DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0)); + delay_fb_mixer[instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.delay_feedback[instance_id], DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0), true)); // REVERB - reverb_mixer_r.gain(instance_id, configuration.fx.reverb_send[instance_id] / 100.0); - reverb_mixer_l.gain(instance_id, configuration.fx.reverb_send[instance_id] / 100.0); + reverb_mixer_r.gain(instance_id, pseudo_log_curve(configuration.fx.reverb_send[instance_id] / 100.0, true)); + reverb_mixer_l.gain(instance_id, pseudo_log_curve(configuration.fx.reverb_send[instance_id] / 100.0, true)); } // REVERB @@ -1804,8 +1804,8 @@ void set_fx_params(void) freeverb_r.damping(mapfloat(configuration.fx.reverb_damping, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 0.0, 1.0)); freeverb_l.roomsize(mapfloat(configuration.fx.reverb_roomsize, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 0.0, 1.0)); freeverb_l.damping(mapfloat(configuration.fx.reverb_damping, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 0.0, 1.0)); - master_mixer_r.gain(3, configuration.fx.reverb_level / 100.0); - master_mixer_l.gain(3, configuration.fx.reverb_level / 100.0); + master_mixer_r.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100.0, true)); + master_mixer_l.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100.0, true)); #endif } @@ -1819,7 +1819,7 @@ void set_voiceconfig_params(uint8_t instance_id) MicroDexed[instance_id]->doRefreshVoice(); // Dexed output level - dexed_level[instance_id]->gain(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX)); + dexed_level[instance_id]->gain(pseudo_log_curve(mapfloat(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX), true)); // PANORAMA mono2stereo[instance_id]->panorama(mapfloat(configuration.dexed[instance_id].pan, PANORAMA_MIN, PANORAMA_MAX, -1.0, 1.0)); diff --git a/UI.hpp b/UI.hpp index 0b5d52b..74d611b 100644 --- a/UI.hpp +++ b/UI.hpp @@ -56,6 +56,7 @@ extern void eeprom_update_sys(void); extern void eeprom_update_performance(void); extern void eeprom_update_fx(void); extern void eeprom_update_dexed(uint8_t instance_id); +extern float pseudo_log_curve(float value, bool type); extern uint8_t selected_instance_id; #ifdef DISPLAY_LCD_SPI @@ -909,7 +910,7 @@ void UI_func_reverb_roomsize(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Reverb Room", configuration.fx.reverb_roomsize, 1.0, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 2, false, false, true); + lcd_display_bar_int("Reverb Room", configuration.fx.reverb_roomsize, 1.0, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 3, false, false, true); } if (LCDML.FUNC_loop()) // ****** LOOP ********* @@ -921,7 +922,7 @@ void UI_func_reverb_roomsize(uint8_t param) else if (LCDML.BT_checkUp()) configuration.fx.reverb_roomsize = constrain(configuration.fx.reverb_roomsize - ENCODER[ENC_R].speed(), REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX); } - lcd_display_bar_int("Reverb Room", configuration.fx.reverb_roomsize, 1.0, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 2, false, false, false); + lcd_display_bar_int("Reverb Room", configuration.fx.reverb_roomsize, 1.0, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 3, false, false, false); freeverb_r.roomsize(mapfloat(configuration.fx.reverb_roomsize, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 0.0, 1.0)); freeverb_l.roomsize(mapfloat(configuration.fx.reverb_roomsize, REVERB_ROOMSIZE_MIN, REVERB_ROOMSIZE_MAX, 0.0, 1.0)); @@ -942,7 +943,7 @@ void UI_func_reverb_damping(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Reverb Damp.", configuration.fx.reverb_damping, 1.0, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 2, false, false, true); + lcd_display_bar_int("Reverb Damp.", configuration.fx.reverb_damping, 1.0, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 3, false, false, true); } if (LCDML.FUNC_loop()) // ****** LOOP ********* @@ -955,7 +956,7 @@ void UI_func_reverb_damping(uint8_t param) configuration.fx.reverb_damping = constrain(configuration.fx.reverb_damping - ENCODER[ENC_R].speed(), REVERB_DAMPING_MIN, REVERB_DAMPING_MAX); } - lcd_display_bar_int("Reverb Damp.", configuration.fx.reverb_damping, 1.0, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 2, false, false, false); + lcd_display_bar_int("Reverb Damp.", configuration.fx.reverb_damping, 1.0, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 3, false, false, false); freeverb_l.damping(mapfloat(configuration.fx.reverb_damping, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 0.0, 1.0)); freeverb_r.damping(mapfloat(configuration.fx.reverb_damping, REVERB_DAMPING_MIN, REVERB_DAMPING_MAX, 0.0, 1.0)); @@ -976,7 +977,7 @@ void UI_func_reverb_level(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Reverb Level", configuration.fx.reverb_level, 1.0, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 2, false, false, true); + lcd_display_bar_int("Reverb Level", configuration.fx.reverb_level, 1.0, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 3, false, false, true); } if (LCDML.FUNC_loop()) // ****** LOOP ********* @@ -989,10 +990,10 @@ void UI_func_reverb_level(uint8_t param) configuration.fx.reverb_level = constrain(configuration.fx.reverb_level - ENCODER[ENC_R].speed(), REVERB_LEVEL_MIN, REVERB_LEVEL_MAX); } - lcd_display_bar_int("Reverb Level", configuration.fx.reverb_level, 1.0, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 2, false, false, true); + lcd_display_bar_int("Reverb Level", configuration.fx.reverb_level, 1.0, REVERB_LEVEL_MIN, REVERB_LEVEL_MAX, 3, false, false, true); - master_mixer_r.gain(3, configuration.fx.reverb_level / 100.0); - master_mixer_l.gain(3, configuration.fx.reverb_level / 100.0); + master_mixer_r.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100.0, true)); + master_mixer_l.gain(3, pseudo_log_curve(configuration.fx.reverb_level / 100.0, true)); } if (LCDML.FUNC_close()) // ****** STABLE END ********* @@ -1125,7 +1126,7 @@ void UI_func_chorus_depth(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Chorus Dpt.", configuration.fx.chorus_depth[selected_instance_id], 1.0, CHORUS_DEPTH_MIN, CHORUS_DEPTH_MAX, 2, false, false, true); + lcd_display_bar_int("Chorus Dpt.", configuration.fx.chorus_depth[selected_instance_id], 1.0, CHORUS_DEPTH_MIN, CHORUS_DEPTH_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1155,7 +1156,7 @@ void UI_func_chorus_depth(uint8_t param) #endif } - lcd_display_bar_int("Chorus Dpt.", configuration.fx.chorus_depth[selected_instance_id], 1.0, CHORUS_DEPTH_MIN, CHORUS_DEPTH_MAX, 2, false, false, false); + lcd_display_bar_int("Chorus Dpt.", configuration.fx.chorus_depth[selected_instance_id], 1.0, CHORUS_DEPTH_MIN, CHORUS_DEPTH_MAX, 3, false, false, false); chorus_modulator[selected_instance_id]->amplitude(configuration.fx.chorus_depth[selected_instance_id] / 100.0); } @@ -1178,7 +1179,7 @@ void UI_func_chorus_level(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Chorus Lvl.", configuration.fx.chorus_level[selected_instance_id], 1.0, CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 2, false, false, true); + lcd_display_bar_int("Chorus Lvl.", configuration.fx.chorus_level[selected_instance_id], 1.0, CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1208,7 +1209,7 @@ void UI_func_chorus_level(uint8_t param) #endif } - lcd_display_bar_int("Chorus Lvl.", configuration.fx.chorus_level[selected_instance_id], 1.0, CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 2, false, false, false); + lcd_display_bar_int("Chorus Lvl.", configuration.fx.chorus_level[selected_instance_id], 1.0, CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 3, false, false, false); //chorus_mixer[selected_instance_id]->gain(0, 1.0 - pseudo_log_curve(mapfloat(configuration.fx.chorus_level[selected_instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 1.0), true)); //chorus_mixer[selected_instance_id]->gain(1, pseudo_log_curve(mapfloat(configuration.fx.chorus_level[selected_instance_id], CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 1.0), true)); @@ -1234,7 +1235,7 @@ void UI_func_delay_time(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Delay Time", configuration.fx.delay_time[selected_instance_id], 10.0, DELAY_TIME_MIN, DELAY_TIME_MAX, 2, false, false, true); + lcd_display_bar_int("Delay Time", configuration.fx.delay_time[selected_instance_id], 10.0, DELAY_TIME_MIN, DELAY_TIME_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1264,7 +1265,7 @@ void UI_func_delay_time(uint8_t param) #endif } - lcd_display_bar_int("Delay Time", configuration.fx.delay_time[selected_instance_id], 10.0, DELAY_TIME_MIN, DELAY_TIME_MAX, 2, false, false, true); + lcd_display_bar_int("Delay Time", configuration.fx.delay_time[selected_instance_id], 10.0, DELAY_TIME_MIN, DELAY_TIME_MAX, 3, false, false, true); delay_fx[selected_instance_id]->delay(0, configuration.fx.delay_time[selected_instance_id] * 10); } @@ -1287,7 +1288,7 @@ void UI_func_delay_feedback(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Delay Feedb.", configuration.fx.delay_feedback[selected_instance_id], 1.0, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 2, false, false, true); + lcd_display_bar_int("Delay Feedb.", configuration.fx.delay_feedback[selected_instance_id], 1.0, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1317,7 +1318,7 @@ void UI_func_delay_feedback(uint8_t param) #endif } - lcd_display_bar_int("Delay Feedb.", configuration.fx.delay_feedback[selected_instance_id], 1.0, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 2, false, false, false); + lcd_display_bar_int("Delay Feedb.", configuration.fx.delay_feedback[selected_instance_id], 1.0, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 3, false, false, false); delay_fb_mixer[selected_instance_id]->gain(1, configuration.fx.delay_feedback[selected_instance_id] / 100.0); // amount of feedback } @@ -1340,7 +1341,7 @@ void UI_func_delay_level(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Delay Lvl.", configuration.fx.delay_level[selected_instance_id], 1.0, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 2, false, false, true); + lcd_display_bar_int("Delay Lvl.", configuration.fx.delay_level[selected_instance_id], 1.0, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1370,9 +1371,9 @@ void UI_func_delay_level(uint8_t param) #endif } - lcd_display_bar_int("Delay Lvl.", configuration.fx.delay_level[selected_instance_id], 1.0, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 2, false, false, false); + 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); - delay_mixer[selected_instance_id]->gain(1, mapfloat(configuration.fx.delay_level[selected_instance_id], DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0)); + 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), true)); } if (LCDML.FUNC_close()) // ****** STABLE END ********* @@ -1393,7 +1394,7 @@ void UI_func_reverb_send(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Reverb Send", configuration.fx.reverb_send[selected_instance_id], 1.0, REVERB_SEND_MIN, REVERB_SEND_MAX, 2, false, false, true); + lcd_display_bar_int("Reverb Send", configuration.fx.reverb_send[selected_instance_id], 1.0, REVERB_SEND_MIN, REVERB_SEND_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1423,10 +1424,10 @@ void UI_func_reverb_send(uint8_t param) #endif } - lcd_display_bar_int("Reverb Send", configuration.fx.reverb_send[selected_instance_id], 1.0, REVERB_SEND_MIN, REVERB_SEND_MAX, 2, false, false, false); + lcd_display_bar_int("Reverb Send", configuration.fx.reverb_send[selected_instance_id], 1.0, REVERB_SEND_MIN, REVERB_SEND_MAX, 3, false, false, false); - reverb_mixer_r.gain(selected_instance_id, configuration.fx.reverb_send[selected_instance_id] / 100.0); - reverb_mixer_l.gain(selected_instance_id, configuration.fx.reverb_send[selected_instance_id] / 100.0); + reverb_mixer_r.gain(selected_instance_id, pseudo_log_curve(configuration.fx.reverb_send[selected_instance_id] / 100.0, true)); + reverb_mixer_l.gain(selected_instance_id, pseudo_log_curve(configuration.fx.reverb_send[selected_instance_id] / 100.0, true)); } if (LCDML.FUNC_close()) // ****** STABLE END ********* @@ -1447,7 +1448,7 @@ void UI_func_filter_cutoff(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Filter Cut", configuration.dexed[selected_instance_id].filter_cutoff, 1.0, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 2, false, false, true); + lcd_display_bar_int("Filter Cut", configuration.dexed[selected_instance_id].filter_cutoff, 1.0, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1477,7 +1478,7 @@ void UI_func_filter_cutoff(uint8_t param) #endif } - lcd_display_bar_int("Filter Cut", configuration.dexed[selected_instance_id].filter_cutoff, 1.0, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 2, false, false, false); + lcd_display_bar_int("Filter Cut", configuration.dexed[selected_instance_id].filter_cutoff, 1.0, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 3, false, false, false); MicroDexed[selected_instance_id]->fx.Cutoff = mapfloat(configuration.dexed[selected_instance_id].filter_cutoff, FILTER_CUTOFF_MIN, FILTER_CUTOFF_MAX, 1.0, 0.0); } @@ -1500,7 +1501,7 @@ void UI_func_filter_resonance(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(BLOCKBAR); - lcd_display_bar_int("Filter Res", configuration.dexed[selected_instance_id].filter_resonance, 1.0, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 2, false, false, true); + lcd_display_bar_int("Filter Res", configuration.dexed[selected_instance_id].filter_resonance, 1.0, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 3, false, false, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1530,7 +1531,7 @@ void UI_func_filter_resonance(uint8_t param) #endif } - lcd_display_bar_int("Filter Res", configuration.dexed[selected_instance_id].filter_resonance, 1.0, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 2, false, false, false); + lcd_display_bar_int("Filter Res", configuration.dexed[selected_instance_id].filter_resonance, 1.0, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 3, false, false, false); MicroDexed[selected_instance_id]->fx.Reso = mapfloat(configuration.dexed[selected_instance_id].filter_resonance, FILTER_RESONANCE_MIN, FILTER_RESONANCE_MAX, 1.0, 0.0); } @@ -1608,7 +1609,7 @@ void UI_func_tune(uint8_t param) encoderDir[ENC_R].reset(); lcd_special_chars(METERBAR); - lcd_display_meter_int("Fine Tune", configuration.dexed[selected_instance_id].tune, 1.0, -100.0, TUNE_MIN, TUNE_MAX, 2, false, true, true); + lcd_display_meter_int("Fine Tune", configuration.dexed[selected_instance_id].tune, 1.0, -100.0, TUNE_MIN, TUNE_MAX, 3, false, true, true); lcd_active_instance_number(selected_instance_id); lcd.setCursor(14, 0); @@ -1638,7 +1639,7 @@ void UI_func_tune(uint8_t param) #endif } - lcd_display_meter_int("Fine Tune", configuration.dexed[selected_instance_id].tune, 1.0, -100.0, TUNE_MIN, TUNE_MAX, 2, false, true, false); + lcd_display_meter_int("Fine Tune", configuration.dexed[selected_instance_id].tune, 1.0, -100.0, TUNE_MIN, TUNE_MAX, 3, false, true, false); MicroDexed[selected_instance_id]->controllers.masterTune = (int((configuration.dexed[selected_instance_id].tune - 100) / 100.0 * 0x4000) << 11) * (1.0 / 12); MicroDexed[selected_instance_id]->doRefreshVoice(); @@ -1878,7 +1879,7 @@ void UI_func_sound_intensity(uint8_t param) } lcd_display_bar_int("Voice Level", configuration.dexed[selected_instance_id].sound_intensity, 1.0, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 3, false, false, false); - dexed_level[selected_instance_id]->gain(mapfloat(configuration.dexed[selected_instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX)); + dexed_level[selected_instance_id]->gain(pseudo_log_curve(mapfloat(configuration.dexed[selected_instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0.0, SOUND_INTENSITY_AMP_MAX), true)); } if (LCDML.FUNC_close()) // ****** STABLE END ********* diff --git a/config.h b/config.h index 0390fcf..8e8f338 100644 --- a/config.h +++ b/config.h @@ -84,7 +84,7 @@ //************************************************************************************************* //* DEBUG OUTPUT SETTINGS //************************************************************************************************* -#define DEBUG 1 +//#define DEBUG 1 #define SERIAL_SPEED 230400 #define SHOW_XRUN 1 #define SHOW_CPU_LOAD_MSEC 5000