Added engine selection.

dev
Holger Wirtz 2 years ago
parent 3fa0bea577
commit 7b601dc00b
  1. 2
      MicroDexed.ino
  2. 7
      UI.hpp
  3. 3
      addon/SD/PERFORMANCE/0/voice1.json
  4. 3
      addon/SD/PERFORMANCE/0/voice2.json
  5. 2
      config.h
  6. 2
      dexed_sd.cpp

@ -2129,7 +2129,7 @@ void set_voiceconfig_params(uint8_t instance_id) {
MicroDexed[instance_id]->doRefreshVoice();
MicroDexed[instance_id]->setMonoMode(configuration.dexed[instance_id].monopoly);
MicroDexed[instance_id]->setNoteRefreshMode(configuration.dexed[instance_id].note_refresh);
MicroDexed[instance_id]->setEngineType(MKI);
MicroDexed[instance_id]->setEngineType(configuration.dexed[instance_id].engine);
// Dexed output level
MicroDexed[instance_id]->setGain(midi_volume_transform(map(configuration.dexed[instance_id].sound_intensity, SOUND_INTENSITY_MIN, SOUND_INTENSITY_MAX, 0, 127)));

@ -4865,15 +4865,16 @@ void UI_func_engine(uint8_t param) {
display.clear();
display.show(0, 0, 16, "Engine");
display.show(1, 0, 16, "[ ]");
switch (configuration.dexed[selected_instance_id].engine) {
case 0:
display.show(1, 0, 16, "[Modern]");
display.show(1, 1, 6, "Modern");
break;
case 1:
display.show(1, 0, 16, "[Mark I]");
display.show(1, 1, 6, "Mark I");
break;
case 2:
display.show(1, 0, 16, "[OPL]");
display.show(1, 1, 6, "OPL");
break;
}

@ -29,5 +29,6 @@
"portamento_glissando": 0,
"portamento_time": 0,
"op_enabled": 63,
"midi_channel": 2
"midi_channel": 2,
"engine": 1
}

@ -29,5 +29,6 @@
"portamento_glissando": 0,
"portamento_time": 0,
"op_enabled": 63,
"midi_channel": 3
"midi_channel": 3,
"engine": 1
}

@ -525,7 +525,7 @@
#define ENGINE_MIN 0
#define ENGINE_MAX 2
#define ENGINE_DEFAULT 0
#define ENGINE_DEFAULT 1 // 0=Modern, 1=MkI, 2=OPL
#define PERFORMANCE_NUM_MIN 0
#define PERFORMANCE_NUM_MAX 99

@ -614,6 +614,7 @@ bool load_sd_voiceconfig_json(uint8_t vc, uint8_t instance_id) {
configuration.dexed[instance_id].portamento_time = data_json["portamento_time"];
configuration.dexed[instance_id].op_enabled = data_json["op_enabled"];
configuration.dexed[instance_id].midi_channel = data_json["midi_channel"];
configuration.dexed[instance_id].engine = data_json["engine"];
check_configuration_dexed(instance_id);
set_voiceconfig_params(instance_id);
@ -695,6 +696,7 @@ bool save_sd_voiceconfig_json(uint8_t vc, uint8_t instance_id) {
data_json["portamento_time"] = configuration.dexed[instance_id].portamento_time;
data_json["op_enabled"] = configuration.dexed[instance_id].op_enabled;
data_json["midi_channel"] = configuration.dexed[instance_id].midi_channel;
data_json["engine"] = configuration.dexed[instance_id].engine;
#if defined(DEBUG) && defined(DEBUG_SHOW_JSON)
Serial.println(F("Write JSON data:"));

Loading…
Cancel
Save