@ -1451,7 +1451,7 @@ 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)));
//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)));
//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 , pseudo_log_curve ( 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 ) ) ;
delay_mixer [ instance_id ] - > gain ( 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 ) ) ) ;
delay_fb_mixer [ instance_id ] - > gain ( 0 , 1.0 ) ;
@ -1757,9 +1757,7 @@ void set_fx_params(void)
for ( uint8_t instance_id = 0 ; instance_id < NUM_DEXED ; instance_id + + )
{
// CHORUS
//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)));
//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)));
//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 ( 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 ) ) ;
switch ( configuration . fx . chorus_waveform [ instance_id ] )
{
@ -1847,12 +1845,12 @@ float pseudo_log_curve(float value)
{
const float _pseudo_log = 1048575 / ( float ) ( 1 < < 20 ) ;
# ifdef DEBUG
/* #ifdef DEBUG
Serial . print ( F ( " value in: " ) ) ;
Serial . print ( value , 3 ) ;
Serial . print ( F ( " value out: " ) ) ;
Serial . println ( mapfloat ( _pseudo_log * arm_sin_f32 ( value ) , 0.0 , _pseudo_log * arm_sin_f32 ( 1.0 ) , 0.0 , 1.0 ) , 3 ) ;
# endif
# endif * /
return ( mapfloat ( _pseudo_log * arm_sin_f32 ( value ) , 0.0 , _pseudo_log * arm_sin_f32 ( 1.0 ) , 0.0 , 1.0 ) ) ;
}