|
|
@ -191,7 +191,7 @@ void lcdml_menu_control(void) |
|
|
|
break; |
|
|
|
break; |
|
|
|
case MENU_VOICE: |
|
|
|
case MENU_VOICE: |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("State: MENU_VOICE, Encoder left down")); |
|
|
|
Serial.println(F("State: MENU_VOICE, Encoder left up")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
switch (menu_voice) |
|
|
|
switch (menu_voice) |
|
|
|
{ |
|
|
|
{ |
|
|
@ -204,7 +204,7 @@ void lcdml_menu_control(void) |
|
|
|
} |
|
|
|
} |
|
|
|
break; |
|
|
|
break; |
|
|
|
case MENU_VOICE_SOUND: |
|
|
|
case MENU_VOICE_SOUND: |
|
|
|
if (configuration.voice < 31) |
|
|
|
if (configuration.voice < MAX_VOICES) |
|
|
|
configuration.voice++; |
|
|
|
configuration.voice++; |
|
|
|
else |
|
|
|
else |
|
|
|
{ |
|
|
|
{ |
|
|
@ -212,10 +212,10 @@ void lcdml_menu_control(void) |
|
|
|
{ |
|
|
|
{ |
|
|
|
configuration.bank++; |
|
|
|
configuration.bank++; |
|
|
|
configuration.voice = 0; |
|
|
|
configuration.voice = 0; |
|
|
|
load_sysex(configuration.bank, configuration.voice); |
|
|
|
|
|
|
|
get_voice_names_from_bank(configuration.bank); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
load_sysex(configuration.bank, configuration.voice); |
|
|
|
|
|
|
|
get_voice_names_from_bank(configuration.bank); |
|
|
|
eeprom_write(); |
|
|
|
eeprom_write(); |
|
|
|
} |
|
|
|
} |
|
|
|
UI_func_voice_selection(0); |
|
|
|
UI_func_voice_selection(0); |
|
|
@ -244,7 +244,7 @@ void lcdml_menu_control(void) |
|
|
|
break; |
|
|
|
break; |
|
|
|
case MENU_VOICE: |
|
|
|
case MENU_VOICE: |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("State: MENU_VOICE, Encoder left up")); |
|
|
|
Serial.println(F("State: MENU_VOICE, Encoder left down")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
switch (menu_voice) |
|
|
|
switch (menu_voice) |
|
|
|
{ |
|
|
|
{ |
|
|
@ -265,10 +265,10 @@ void lcdml_menu_control(void) |
|
|
|
{ |
|
|
|
{ |
|
|
|
configuration.bank--; |
|
|
|
configuration.bank--; |
|
|
|
configuration.voice = 31; |
|
|
|
configuration.voice = 31; |
|
|
|
load_sysex(configuration.bank, configuration.voice); |
|
|
|
|
|
|
|
get_voice_names_from_bank(configuration.bank); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
load_sysex(configuration.bank, configuration.voice); |
|
|
|
|
|
|
|
get_voice_names_from_bank(configuration.bank); |
|
|
|
eeprom_write(); |
|
|
|
eeprom_write(); |
|
|
|
} |
|
|
|
} |
|
|
|
UI_func_voice_selection(0); |
|
|
|
UI_func_voice_selection(0); |
|
|
@ -344,9 +344,8 @@ void lcdml_menu_control(void) |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("Volume +")); |
|
|
|
Serial.println(F("Volume +")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
if (configuration.vol < 0.95) |
|
|
|
if (configuration.vol < 0.96) |
|
|
|
{ |
|
|
|
{ |
|
|
|
//set_volume(configuration.vol + 0.05, configuration.pan);
|
|
|
|
|
|
|
|
soften_volume.diff = 0.05 / SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.diff = 0.05 / SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.steps = SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.steps = SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
eeprom_write(); |
|
|
|
eeprom_write(); |
|
|
@ -369,9 +368,8 @@ void lcdml_menu_control(void) |
|
|
|
#ifdef DEBUG |
|
|
|
#ifdef DEBUG |
|
|
|
Serial.println(F("Volume -")); |
|
|
|
Serial.println(F("Volume -")); |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
if (configuration.vol > 0.05) |
|
|
|
if (configuration.vol > 0.04) |
|
|
|
{ |
|
|
|
{ |
|
|
|
//set_volume(configuration.vol - 0.05, configuration.pan);
|
|
|
|
|
|
|
|
soften_volume.diff = -0.05 / SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.diff = -0.05 / SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.steps = SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
soften_volume.steps = SOFTEN_VALUE_CHANGE_STEPS; |
|
|
|
eeprom_write(); |
|
|
|
eeprom_write(); |
|
|
@ -731,17 +729,18 @@ void UI_func_volume(uint8_t param) |
|
|
|
|
|
|
|
|
|
|
|
// update LCD content
|
|
|
|
// update LCD content
|
|
|
|
LCDML.DISP_clear(); |
|
|
|
LCDML.DISP_clear(); |
|
|
|
lcd.setCursor(0, 0); // set cursor
|
|
|
|
lcd.show(0, 0, 8, "Volume: "); |
|
|
|
lcd.print("Volume"); // print change content
|
|
|
|
lcd.show(0, 9, 3, configuration.vol * 100.0 + 0.5); |
|
|
|
lcd.setCursor(0, 1); // set cursor
|
|
|
|
lcd.setCursor(1, 1); |
|
|
|
|
|
|
|
|
|
|
|
for (uint8_t i = 0; i < LCD_cols; i++) |
|
|
|
for (uint8_t i = 0; i < LCD_cols; i++) |
|
|
|
{ |
|
|
|
{ |
|
|
|
if (i < int(LCD_cols * configuration.vol + 0.5)) |
|
|
|
if (i < int((LCD_cols - 2) * configuration.vol + 0.5)) |
|
|
|
lcd.print("*"); |
|
|
|
lcd.print("*"); |
|
|
|
else |
|
|
|
else |
|
|
|
lcd.print(" "); |
|
|
|
lcd.print(" "); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
lcd.show(1, 0, 1, "["); |
|
|
|
|
|
|
|
lcd.show(1, 15, 1, "]"); |
|
|
|
} |
|
|
|
} |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
#endif |
|
|
|