From 55d92f76857d265d60e6b832056d895a67ddcff5 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:22:41 -0300 Subject: [PATCH 01/37] Update performanceconfig.cpp --- src/performanceconfig.cpp | 98 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 96 insertions(+), 2 deletions(-) diff --git a/src/performanceconfig.cpp b/src/performanceconfig.cpp index 1204103..e66fbd9 100644 --- a/src/performanceconfig.cpp +++ b/src/performanceconfig.cpp @@ -98,7 +98,22 @@ bool CPerformanceConfig::Load (void) PropertyName.Format ("ReverbSend%u", nTG+1); m_nReverbSend[nTG] = m_Properties.GetNumber (PropertyName, 50); - } + + PropertyName.Format ("PitchBenderRange%u", nTG+1); + m_nPitchBenderRange[nTG] = m_Properties.GetNumber (PropertyName, 2); + + PropertyName.Format ("PitchBenderStep%u", nTG+1); + m_nPitchBenderStep[nTG] = m_Properties.GetNumber (PropertyName, 0); + + PropertyName.Format ("PortamentoMode%u", nTG+1); + m_nPitchPortamentoMode[nTG] = m_Properties.GetNumber (PropertyName, 0); + + PropertyName.Format ("PortamentoGlissando%u", nTG+1); + m_nPortamentoGlissando[nTG] = m_Properties.GetNumber (PropertyName, 0); + + PropertyName.Format ("PortamentoTime%u", nTG+1); + m_nPortamentoTime[nTG] = m_Properties.GetNumber (PropertyName, 0); + } m_bCompressorEnable = m_Properties.GetNumber ("CompressorEnable", 1) != 0; @@ -169,7 +184,22 @@ bool CPerformanceConfig::Save (void) PropertyName.Format ("ReverbSend%u", nTG+1); m_Properties.SetNumber (PropertyName, m_nReverbSend[nTG]); - } + + PropertyName.Format ("PitchBenderRange%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPitchBenderRange[nTG]); + + PropertyName.Format ("PitchBenderStep%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPitchBenderStep[nTG]); + + PropertyName.Format ("PortamentoMode%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPortamentoMode[nTG]); + + PropertyName.Format ("PortamentoGlissando%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPortamentoGlissando[nTG]); + + PropertyName.Format ("PortamentoTime%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPortamentoTime[nTG]); + } m_Properties.SetNumber ("CompressorEnable", m_bCompressorEnable ? 1 : 0); @@ -407,3 +437,67 @@ void CPerformanceConfig::SetReverbLevel (unsigned nValue) { m_nReverbLevel = nValue; } +// Pitch bender and portamento: +void CPerformanceConfig::SetPitchBenderRange (unsigned nValue, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nPitchBenderRange[nTG] = nValue; +} + +unsigned CPerformanceConfig::GetPitchBenderRange (unsigned nTG) const +{ + assert (nTG < CConfig::ToneGenerators); + return m_nPitchBenderRange[nTG]; +} + + +void CPerformanceConfig::SetPitchBenderStep (unsigned nValue, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nPitchBenderStep[nTG] = nValue; +} + +unsigned CPerformanceConfig::GetPitchBenderStep (unsigned nTG) const +{ + assert (nTG < CConfig::ToneGenerators); + return m_nPitchBenderStep[nTG]; +} + + +void CPerformanceConfig::SetPortamentoMode (unsigned nValue, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoMode[nTG] = nValue; +} + +unsigned CPerformanceConfig::GetPortamentoMode (unsigned nTG) const +{ + assert (nTG < CConfig::ToneGenerators); + return m_nPortamentoMode[nTG]; +} + + +void CPerformanceConfig::SetPortamentoGlissando (unsigned nValue, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoGlissando[nTG] = nValue; +} + +unsigned CPerformanceConfig::GetPortamentoGlissando (unsigned nTG) const +{ + assert (nTG < CConfig::ToneGenerators); + return m_nPortamentoGlissando[nTG]; +} + + +void CPerformanceConfig::SetPortamentoTime (unsigned nValue, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoTime[nTG] = nValue; +} + +unsigned CPerformanceConfig::GetPortamentoTime (unsigned nTG) const +{ + assert (nTG < CConfig::ToneGenerators); + return m_nPortamentoTime[nTG]; +} From ac1ecd359266623e4e7aba0b679e253ec942bfad Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:24:40 -0300 Subject: [PATCH 02/37] Update performanceconfig.h --- src/performanceconfig.h | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/src/performanceconfig.h b/src/performanceconfig.h index 2d18344..8b5887f 100644 --- a/src/performanceconfig.h +++ b/src/performanceconfig.h @@ -50,7 +50,12 @@ public: unsigned GetNoteLimitHigh (unsigned nTG) const; // 0 .. 127 int GetNoteShift (unsigned nTG) const; // -24 .. 24 unsigned GetReverbSend (unsigned nTG) const; // 0 .. 127 - + unsigned GetPitchBenderRange (unsigned nTG) const; // 0 .. 12 + unsigned GetPitchBenderStep (unsigned nTG) const; // 0 .. 12 + unsigned GetPortamentoMode (unsigned nTG) const; // 0 .. 1 + unsigned GetPortamentoGlissando (unsigned nTG) const; // 0 .. 1 + unsigned GetPortamentoTime (unsigned nTG) const; // 0 .. 99 + void SetBankNumber (unsigned nValue, unsigned nTG); void SetVoiceNumber (unsigned nValue, unsigned nTG); void SetMIDIChannel (unsigned nValue, unsigned nTG); @@ -63,6 +68,11 @@ public: void SetNoteLimitHigh (unsigned nValue, unsigned nTG); void SetNoteShift (int nValue, unsigned nTG); void SetReverbSend (unsigned nValue, unsigned nTG); + void SetPitchBenderRange (unsigned nValue, unsigned nTG); + void SetPitchBenderStep (unsigned nValue, unsigned nTG); + void SetPortamentoMode (unsigned nValue, unsigned nTG); + void SetPortamentoGlissando (unsigned nValue, unsigned nTG); + void SetPortamentoTime (unsigned nValue, unsigned nTG); // Effects bool GetCompressorEnable (void) const; @@ -98,6 +108,11 @@ private: unsigned m_nNoteLimitHigh[CConfig::ToneGenerators]; int m_nNoteShift[CConfig::ToneGenerators]; int m_nReverbSend[CConfig::ToneGenerators]; + unsigned m_nPitchBenderRange[CConfig::ToneGenerators]; + unsigned m_nPitchBenderStep[CConfig::ToneGenerators]; + unsigned m_nPortamentoMode[CConfig::ToneGenerators]; + unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; + unsigned m_nPortamentoTime[CConfig::ToneGenerators]; bool m_bCompressorEnable; bool m_bReverbEnable; From 5d13c42d589d4a6c948a5a041ef26a016f0aa7f9 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:34:27 -0300 Subject: [PATCH 03/37] Update minidexed.cpp --- src/minidexed.cpp | 93 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 92 insertions(+), 1 deletion(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 68908bf..dbac858 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -62,6 +62,11 @@ CMiniDexed::CMiniDexed (CConfig *pConfig, CInterruptSystem *pInterrupt, m_nCutoff[i] = 99; m_nResonance[i] = 0; m_nMIDIChannel[i] = CMIDIDevice::Disabled; + m_nPitchBenderRange[i] = 2; + m_nPitchBenderStep[i] = 0; + m_nPortamentoMode[i] = 0; + m_nPortamentoGlissando[i] = 0; + m_nPortamentoTime[i] = 0; m_nNoteLimitLow[i] = 0; m_nNoteLimitHigh[i] = 127; @@ -165,7 +170,7 @@ bool CMiniDexed::Initialize (void) m_pTG[i]->setTranspose (24); - m_pTG[i]->setPBController (12, 1); + m_pTG[i]->setPBController (2, 0); m_pTG[i]->setMWController (99, 7, 0); tg_mixer->pan(i,mapfloat(m_nPan[i],0,127,0.0f,1.0f)); @@ -186,6 +191,11 @@ bool CMiniDexed::Initialize (void) SetMasterTune (m_PerformanceConfig.GetDetune (nTG), nTG); SetCutoff (m_PerformanceConfig.GetCutoff (nTG), nTG); SetResonance (m_PerformanceConfig.GetResonance (nTG), nTG); + SetPitchBenderRange (m_PerformanceConfig.GetPitchBenderRange (nTG), nTG); + SetPitchBenderStep (m_PerformanceConfig.GetPitchBenderStep (nTG), nTG); + SetPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); + SetPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); + SetPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); m_nNoteLimitLow[nTG] = m_PerformanceConfig.GetNoteLimitLow (nTG); m_nNoteLimitHigh[nTG] = m_PerformanceConfig.GetNoteLimitHigh (nTG); @@ -433,6 +443,72 @@ void CMiniDexed::SetResonance (int nResonance, unsigned nTG) m_UI.ParameterChanged (); } +void CMiniDexed::SetPitchBenderRange (uint8_t nValue, unsigned nTG) +{ + nValue = constrain (nValue, 0, 12); + + assert (nTG < CConfig::ToneGenerators); + m_nPitchBenderRange[nTG] = nValue; + + assert (m_pTG[nTG]); + m_pTG[nTG]->setPitchbendRange (nValue); + + m_UI.ParameterChanged (); +} + +void CMiniDexed::SetPitchBenderStep (uint8_t nValue, unsigned nTG) +{ + nValue= constrain (nValue, 0, 12); + + assert (nTG < CConfig::ToneGenerators); + m_nPitchBenderStep[nTG] = nValue; + + assert (m_pTG[nTG]); + m_pTG[nTG]->setPitchbendStep (nValue); + + m_UI.ParameterChanged (); +} + +void CMiniDexed::SetPortamentoMode (uint8_t nValue, unsigned nTG) +{ + nValue= constrain (nValue, 0, 1); + + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoMode[nTG] = nValue; + + assert (m_pTG[nTG]); + m_pTG[nTG]->setPortamentoMode (nValue); + + m_UI.ParameterChanged (); +} + +void CMiniDexed::SetPortamentoGlissando (uint8_t nValue, unsigned nTG) +{ + nValue = constrain (nValue, 0, 1); + + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoGlissando[nTG] = nValue; + + assert (m_pTG[nTG]); + m_pTG[nTG]->setPortamentoGlissando (nValue); + + m_UI.ParameterChanged (); +} + +void CMiniDexed::SetPortamentoTime (uint8_t nValue, unsigned nTG) +{ + nValue = constrain (nValue, 0, 99); + + assert (nTG < CConfig::ToneGenerators); + m_nPortamentoTime[nTG] = nValue; + + assert (m_pTG[nTG]); + m_pTG[nTG]->setPortamentoTime (nValue); + + m_UI.ParameterChanged (); +} + + void CMiniDexed::SetMIDIChannel (uint8_t uchChannel, unsigned nTG) { assert (nTG < CConfig::ToneGenerators); @@ -651,6 +727,11 @@ void CMiniDexed::SetTGParameter (TTGParameter Parameter, int nValue, unsigned nT case TGParameterMasterTune: SetMasterTune (nValue, nTG); break; case TGParameterCutoff: SetCutoff (nValue, nTG); break; case TGParameterResonance: SetResonance (nValue, nTG); break; + case TGParameterPitchBenderRange: SetPitchBenderRange (nValue, nTG); break; + case TGParameterPitchBenderStep: SetPitchBenderStep (nValue, nTG); break; + case TGParameterPortamentoMode: SetPortamentoMode (nValue, nTG); break; + case TGParameterPortamentoGlissando: SetPortamentoGlissando (nValue, nTG); break; + case TGParameterPortamentoTime: SetPortamentoTime (nValue, nTG); break; case TGParameterMIDIChannel: assert (0 <= nValue && nValue <= 255); @@ -680,6 +761,11 @@ int CMiniDexed::GetTGParameter (TTGParameter Parameter, unsigned nTG) case TGParameterResonance: return m_nResonance[nTG]; case TGParameterMIDIChannel: return m_nMIDIChannel[nTG]; case TGParameterReverbSend: return m_nReverbSend[nTG]; + case TGParameterPitchBenderRange: return m_nPitchBenderRange[nTG]; + case TGParameterPitchBenderStep: return m_nPitchBenderStep[nTG]; + case TGParameterPortamentoMode: return m_nPortamentoMode[nTG]; + case TGParameterPortamentoGlissando: return m_nPortamentoGlissando[nTG]; + case TGParameterPortamentoTime: return m_nPortamentoTime[nTG]; default: assert (0); @@ -921,6 +1007,11 @@ bool CMiniDexed::SavePerformance (void) m_PerformanceConfig.SetDetune (m_nMasterTune[nTG], nTG); m_PerformanceConfig.SetCutoff (m_nCutoff[nTG], nTG); m_PerformanceConfig.SetResonance (m_nResonance[nTG], nTG); + m_PerformanceConfig.SetPitchBenderRange (m_nPitchBenderRange[nTG], nTG); + m_PerformanceConfig.SetPitchBenderStep (m_nPitchBenderStep[nTG], nTG); + m_PerformanceConfig.SetPortamentoMode (m_nPortamentoMode[nTG], nTG); + m_PerformanceConfig.SetPortamentoGlissando (m_nPortamentoGlissando[nTG], nTG); + m_PerformanceConfig.SetPortamentoTime (m_nPortamentoTime[nTG], nTG); m_PerformanceConfig.SetNoteLimitLow (m_nNoteLimitLow[nTG], nTG); m_PerformanceConfig.SetNoteLimitHigh (m_nNoteLimitHigh[nTG], nTG); From 474bc5923dc4db832fbfa8d6f773679924c9894a Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:36:51 -0300 Subject: [PATCH 04/37] Update minidexed.h --- src/minidexed.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/minidexed.h b/src/minidexed.h index 1292e53..62bbbf5 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -71,6 +71,11 @@ public: void SetCutoff (int nCutoff, unsigned nTG); // 0 .. 99 void SetResonance (int nResonance, unsigned nTG); // 0 .. 99 void SetMIDIChannel (uint8_t uchChannel, unsigned nTG); + void SetPitchBenderRange (uint8_t nValue, unsigned nTG); + void SetPitchBenderStep (uint8_t nValue, unsigned nTG); + void SetPortamentoMode (uint8_t nValue, unsigned nTG); + void SetPortamentoGlissando (uint8_t nValue, unsigned nTG); + void SetPortamentoTime (uint8_t nValuel, unsigned nTG); void keyup (int16_t pitch, unsigned nTG); void keydown (int16_t pitch, uint8_t velocity, unsigned nTG); @@ -111,6 +116,11 @@ public: TGParameterResonance, TGParameterMIDIChannel, TGParameterReverbSend, + TGParameterPitchBenderRange, + TGParameterPitchBenderStep, + TGParameterPortamentoMode, + TGParameterPortamentoGlissando, + TGParameterPortamentoTime, TGParameterUnknown }; @@ -158,6 +168,11 @@ private: int m_nCutoff[CConfig::ToneGenerators]; int m_nResonance[CConfig::ToneGenerators]; unsigned m_nMIDIChannel[CConfig::ToneGenerators]; + unsigned m_nPitchBenderRange[CConfig::ToneGenerators]; + unsigned m_nPitchBenderStepRange[CConfig::ToneGenerators]; + unsigned m_nPortamentoMode[CConfig::ToneGenerators]; + unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; + unsigned m_nPortamentoTime[CConfig::ToneGenerators]; unsigned m_nNoteLimitLow[CConfig::ToneGenerators]; unsigned m_nNoteLimitHigh[CConfig::ToneGenerators]; From 2fc0f58bc892a5b1c542fa9079f43fa1db7ade9d Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:41:11 -0300 Subject: [PATCH 05/37] Update uimenu.cpp --- src/uimenu.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index 51344d9..db45130 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -68,6 +68,8 @@ const CUIMenu::TMenuItem CUIMenu::s_TGMenu[] = {"Detune", EditTGParameter, 0, CMiniDexed::TGParameterMasterTune}, {"Cutoff", EditTGParameter, 0, CMiniDexed::TGParameterCutoff}, {"Resonance", EditTGParameter, 0, CMiniDexed::TGParameterResonance}, + {"Pitch Bender", MenuHandler, s_EditPitchBenderMenu}, + {"Portamento", MenuHandler, s_EditPortamentoMenu}, {"Channel", EditTGParameter, 0, CMiniDexed::TGParameterMIDIChannel}, {"Edit Voice", MenuHandler, s_EditVoiceMenu}, {0} @@ -82,6 +84,21 @@ const CUIMenu::TMenuItem CUIMenu::s_EffectsMenu[] = {0} }; +const CUIMenu::TMenuItem CUIMenu::s_EditPitchBenderMenu[] = +{ + {"Bender Range", EditTGParameter, 0, CMiniDexed::TGParameterPitchBenderRange}, + {"Bender Step", EditTGParameter, 0, CMiniDexed::TGParameterPitchBenderStep}, + {0} +}; + +const CUIMenu::TMenuItem CUIMenu::s_EditPortamentoMenu[] = +{ + {"Mode", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoMode}, + {"Glissando", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoGlissando}, + {"Time", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoTime}, + {0} +}; + #ifdef ARM_ALLOW_MULTI_CORE const CUIMenu::TMenuItem CUIMenu::s_ReverbMenu[] = @@ -187,6 +204,11 @@ const CUIMenu::TParameter CUIMenu::s_TGParameter[CMiniDexed::TGParameterUnknown] {0, 99, 1}, // TGParameterResonance {0, CMIDIDevice::ChannelUnknown-1, 1, ToMIDIChannel}, // TGParameterMIDIChannel {0, 99, 1} // TGParameterReverbSend + {0, 12, 1}, // TGParameterPitchBenderRange + {0, 12, 1}, // TGParameterPitchBenderStep + {0, 1, 1}, // TGParameterPortamentoMode + {0, 1, 1}, // TGParameterPortamentoGlissando + {0, 99, 1} // TGParameterPortamentoTime }; // must match DexedVoiceParameters in Synth_Dexed From 56492caad7943c3ea1e64da942148ec4c2571026 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:48:24 -0300 Subject: [PATCH 06/37] Update performance.ini --- src/performance.ini | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/src/performance.ini b/src/performance.ini index d1fcff1..6b7dc15 100644 --- a/src/performance.ini +++ b/src/performance.ini @@ -15,6 +15,11 @@ #NoteLimitHigh#=127 # 0 .. 127, C-2 .. G8 #NoteShift#=0 # -24 .. 24 #ReverbSend#=0 # 0 .. 99 +#PitchBenderRange#=2 +#PitchBenderStep#=0 +#PortamentoMode#=0 +#PortamentoGlissando#=0 +#PortamentoTime#=0 # TG1 BankNumber1=0 @@ -29,6 +34,11 @@ NoteLimitLow1=0 NoteLimitHigh1=127 NoteShift1=0 ReverbSend1=99 +PitchBenderRange1=2 +PitchBenderStep1=0 +PortamentoMode1=0 +PortamentoGlissando1=0 +PortamentoTime1=0 # TG2 BankNumber2=0 @@ -43,6 +53,11 @@ NoteLimitLow2=0 NoteLimitHigh2=127 NoteShift2=0 ReverbSend2=70 +PitchBenderRange2=2 +PitchBenderStep2=0 +PortamentoMode2=0 +PortamentoGlissando2=0 +PortamentoTime2=0 # TG3 BankNumber3=0 @@ -57,6 +72,11 @@ NoteLimitLow3=0 NoteLimitHigh3=127 NoteShift3=0 ReverbSend3=0 +PitchBenderRange3=2 +PitchBenderStep3=0 +PortamentoMode3=0 +PortamentoGlissando3=0 +PortamentoTime3=0 # TG4 BankNumber4=0 @@ -71,6 +91,11 @@ NoteLimitLow4=0 NoteLimitHigh4=127 NoteShift4=0 ReverbSend4=0 +PitchBenderRange4=2 +PitchBenderStep4=0 +PortamentoMode4=0 +PortamentoGlissando4=0 +PortamentoTime4=0 # TG5 BankNumber5=0 @@ -85,6 +110,11 @@ NoteLimitLow5=0 NoteLimitHigh5=127 NoteShift5=0 ReverbSend5=0 +PitchBenderRange5=2 +PitchBenderStep5=0 +PortamentoMode5=0 +PortamentoGlissando5=0 +PortamentoTime5=0 # TG6 BankNumber6=0 @@ -99,6 +129,11 @@ NoteLimitLow6=0 NoteLimitHigh6=127 NoteShift6=0 ReverbSend6=0 +PitchBenderRange6=2 +PitchBenderStep6=0 +PortamentoMode6=0 +PortamentoGlissando6=0 +PortamentoTime6=0 # TG7 BankNumber7=0 @@ -113,6 +148,11 @@ NoteLimitLow7=0 NoteLimitHigh7=127 NoteShift7=0 ReverbSend7=0 +PitchBenderRange7=2 +PitchBenderStep7=0 +PortamentoMode7=0 +PortamentoGlissando7=0 +PortamentoTime7=0 # TG8 BankNumber8=0 @@ -127,6 +167,11 @@ NoteLimitLow8=0 NoteLimitHigh8=127 NoteShift8=0 ReverbSend8=0 +PitchBenderRange8=2 +PitchBenderStep8=0 +PortamentoMode8=0 +PortamentoGlissando8=0 +PortamentoTime8=0 # Effects #CompressorEnable=1 # 0: off, 1: on From d74da5b79f98c85f9f751cc1bb9c62396f72499b Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 09:49:13 -0300 Subject: [PATCH 07/37] Update performance.ini --- src/performance.ini | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/performance.ini b/src/performance.ini index 6b7dc15..843f9d5 100644 --- a/src/performance.ini +++ b/src/performance.ini @@ -15,11 +15,11 @@ #NoteLimitHigh#=127 # 0 .. 127, C-2 .. G8 #NoteShift#=0 # -24 .. 24 #ReverbSend#=0 # 0 .. 99 -#PitchBenderRange#=2 -#PitchBenderStep#=0 -#PortamentoMode#=0 -#PortamentoGlissando#=0 -#PortamentoTime#=0 +#PitchBenderRange#=2 # 0 .. 12 +#PitchBenderStep#=0 # 0 .. 12 +#PortamentoMode#=0 # 0 .. 1 +#PortamentoGlissando#=0 # 0 .. 1 +#PortamentoTime#=0 # 0 .. 99 # TG1 BankNumber1=0 From 693932b0fb5253a7c3ef7738f42caff6e07d4036 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 10:08:39 -0300 Subject: [PATCH 08/37] Update performanceconfig.cpp --- src/performanceconfig.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/performanceconfig.cpp b/src/performanceconfig.cpp index e66fbd9..a92b148 100644 --- a/src/performanceconfig.cpp +++ b/src/performanceconfig.cpp @@ -106,7 +106,7 @@ bool CPerformanceConfig::Load (void) m_nPitchBenderStep[nTG] = m_Properties.GetNumber (PropertyName, 0); PropertyName.Format ("PortamentoMode%u", nTG+1); - m_nPitchPortamentoMode[nTG] = m_Properties.GetNumber (PropertyName, 0); + m_nPortamentoMode[nTG] = m_Properties.GetNumber (PropertyName, 0); PropertyName.Format ("PortamentoGlissando%u", nTG+1); m_nPortamentoGlissando[nTG] = m_Properties.GetNumber (PropertyName, 0); From 32a8041b90ac8201e5f8f5b7a582e71d9f2637c1 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 10:10:55 -0300 Subject: [PATCH 09/37] Update minidexed.h --- src/minidexed.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/minidexed.h b/src/minidexed.h index 62bbbf5..cf3f3cd 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -169,7 +169,7 @@ private: int m_nResonance[CConfig::ToneGenerators]; unsigned m_nMIDIChannel[CConfig::ToneGenerators]; unsigned m_nPitchBenderRange[CConfig::ToneGenerators]; - unsigned m_nPitchBenderStepRange[CConfig::ToneGenerators]; + unsigned m_nPitchBenderStep[CConfig::ToneGenerators]; unsigned m_nPortamentoMode[CConfig::ToneGenerators]; unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; unsigned m_nPortamentoTime[CConfig::ToneGenerators]; From c613500846f2e8f93d035e2966410a4b18ecde6b Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 10:14:12 -0300 Subject: [PATCH 10/37] Update uimenu.h --- src/uimenu.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/uimenu.h b/src/uimenu.h index f48f659..ac1dd8e 100644 --- a/src/uimenu.h +++ b/src/uimenu.h @@ -132,7 +132,9 @@ private: static const TMenuItem s_EditVoiceMenu[]; static const TMenuItem s_OperatorMenu[]; static const TMenuItem s_SaveMenu[]; - + static const TMenuItem s_EditPitchBenderMenu[]; + static const TMenuItem s_EditPortamentoMenu[]; + static const TParameter s_GlobalParameter[]; static const TParameter s_TGParameter[]; static const TParameter s_VoiceParameter[]; From 0e1432e9bf562c36574ec0f5df8898baa09400de Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 10:15:53 -0300 Subject: [PATCH 11/37] Update uimenu.cpp --- src/uimenu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index db45130..abaa5c9 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -203,7 +203,7 @@ const CUIMenu::TParameter CUIMenu::s_TGParameter[CMiniDexed::TGParameterUnknown] {0, 99, 1}, // TGParameterCutoff {0, 99, 1}, // TGParameterResonance {0, CMIDIDevice::ChannelUnknown-1, 1, ToMIDIChannel}, // TGParameterMIDIChannel - {0, 99, 1} // TGParameterReverbSend + {0, 99, 1}, // TGParameterReverbSend {0, 12, 1}, // TGParameterPitchBenderRange {0, 12, 1}, // TGParameterPitchBenderStep {0, 1, 1}, // TGParameterPortamentoMode From 02a7005da5c6a8d687f6b04377ce8a1c07fa395d Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 10:33:36 -0300 Subject: [PATCH 12/37] Update minidexed.h --- src/minidexed.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/minidexed.h b/src/minidexed.h index cf3f3cd..78a3ea4 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -75,7 +75,7 @@ public: void SetPitchBenderStep (uint8_t nValue, unsigned nTG); void SetPortamentoMode (uint8_t nValue, unsigned nTG); void SetPortamentoGlissando (uint8_t nValue, unsigned nTG); - void SetPortamentoTime (uint8_t nValuel, unsigned nTG); + void SetPortamentoTime (uint8_t nValue, unsigned nTG); void keyup (int16_t pitch, unsigned nTG); void keydown (int16_t pitch, uint8_t velocity, unsigned nTG); From 51321d5d9aee1ec51d668a9b6e2bd4cfb84cdd55 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 12:54:34 -0300 Subject: [PATCH 13/37] Update minidexed.h --- src/minidexed.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/minidexed.h b/src/minidexed.h index 78a3ea4..561c2b9 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -73,9 +73,9 @@ public: void SetMIDIChannel (uint8_t uchChannel, unsigned nTG); void SetPitchBenderRange (uint8_t nValue, unsigned nTG); void SetPitchBenderStep (uint8_t nValue, unsigned nTG); - void SetPortamentoMode (uint8_t nValue, unsigned nTG); - void SetPortamentoGlissando (uint8_t nValue, unsigned nTG); - void SetPortamentoTime (uint8_t nValue, unsigned nTG); + void SetPortaMode (uint8_t nValue, unsigned nTG); + void SetPortaGlissando (uint8_t nValue, unsigned nTG); + void SetPortaTime (uint8_t nValue, unsigned nTG); void keyup (int16_t pitch, unsigned nTG); void keydown (int16_t pitch, uint8_t velocity, unsigned nTG); From 86d586492fe2585d2016088ed0d1049ade3661fc Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 13:01:42 -0300 Subject: [PATCH 14/37] Update minidexed.cpp --- src/minidexed.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index dbac858..95f8998 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -193,9 +193,9 @@ bool CMiniDexed::Initialize (void) SetResonance (m_PerformanceConfig.GetResonance (nTG), nTG); SetPitchBenderRange (m_PerformanceConfig.GetPitchBenderRange (nTG), nTG); SetPitchBenderStep (m_PerformanceConfig.GetPitchBenderStep (nTG), nTG); - SetPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); - SetPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); - SetPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); + SetPortaMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); + SetPortaGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); + SetPortaTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); m_nNoteLimitLow[nTG] = m_PerformanceConfig.GetNoteLimitLow (nTG); m_nNoteLimitHigh[nTG] = m_PerformanceConfig.GetNoteLimitHigh (nTG); @@ -469,7 +469,7 @@ void CMiniDexed::SetPitchBenderStep (uint8_t nValue, unsigned nTG) m_UI.ParameterChanged (); } -void CMiniDexed::SetPortamentoMode (uint8_t nValue, unsigned nTG) +void CMiniDexed::SetPortaMode (uint8_t nValue, unsigned nTG) { nValue= constrain (nValue, 0, 1); @@ -482,7 +482,7 @@ void CMiniDexed::SetPortamentoMode (uint8_t nValue, unsigned nTG) m_UI.ParameterChanged (); } -void CMiniDexed::SetPortamentoGlissando (uint8_t nValue, unsigned nTG) +void CMiniDexed::SetPortaGlissando (uint8_t nValue, unsigned nTG) { nValue = constrain (nValue, 0, 1); @@ -495,7 +495,7 @@ void CMiniDexed::SetPortamentoGlissando (uint8_t nValue, unsigned nTG) m_UI.ParameterChanged (); } -void CMiniDexed::SetPortamentoTime (uint8_t nValue, unsigned nTG) +void CMiniDexed::SetPortaTime (uint8_t nValue, unsigned nTG) { nValue = constrain (nValue, 0, 99); @@ -729,9 +729,9 @@ void CMiniDexed::SetTGParameter (TTGParameter Parameter, int nValue, unsigned nT case TGParameterResonance: SetResonance (nValue, nTG); break; case TGParameterPitchBenderRange: SetPitchBenderRange (nValue, nTG); break; case TGParameterPitchBenderStep: SetPitchBenderStep (nValue, nTG); break; - case TGParameterPortamentoMode: SetPortamentoMode (nValue, nTG); break; - case TGParameterPortamentoGlissando: SetPortamentoGlissando (nValue, nTG); break; - case TGParameterPortamentoTime: SetPortamentoTime (nValue, nTG); break; + case TGParameterPortamentoMode: SetPortaMode (nValue, nTG); break; + case TGParameterPortamentoGlissando: SetPortaGlissando (nValue, nTG); break; + case TGParameterPortamentoTime: SetPortaTime (nValue, nTG); break; case TGParameterMIDIChannel: assert (0 <= nValue && nValue <= 255); From 23b11b1e14cd10dd9c33191a27362d863e31e82a Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 5 May 2022 15:39:28 -0300 Subject: [PATCH 15/37] Update minidexed.cpp --- src/minidexed.cpp | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 95f8998..6587242 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -477,8 +477,9 @@ void CMiniDexed::SetPortaMode (uint8_t nValue, unsigned nTG) m_nPortamentoMode[nTG] = nValue; assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoMode (nValue); - + // m_pTG[nTG]->setPortamentoMode (nValue); // uncoment and comment following in news version of dexed + m_pTG[nTG]->setPortamentoMode (nValue, m_nPortamentoGlissando[nTG], m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_UI.ParameterChanged (); } @@ -490,8 +491,9 @@ void CMiniDexed::SetPortaGlissando (uint8_t nValue, unsigned nTG) m_nPortamentoGlissando[nTG] = nValue; assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoGlissando (nValue); - + // m_pTG[nTG]->setPortamentoGlissando (nValue); // uncoment and comment following in news version of dexed + m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], nValue, m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_UI.ParameterChanged (); } @@ -503,8 +505,9 @@ void CMiniDexed::SetPortaTime (uint8_t nValue, unsigned nTG) m_nPortamentoTime[nTG] = nValue; assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoTime (nValue); - + // m_pTG[nTG]->setPortamentoTime (nValue); // uncoment and comment following in news version of dexed + m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], m_nPortamentoGlissando[nTG], nValue); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_UI.ParameterChanged (); } From fad2ae4ba410bf80394ad3fd3d5a661160ab5554 Mon Sep 17 00:00:00 2001 From: arsamus Date: Fri, 6 May 2022 17:00:55 -0300 Subject: [PATCH 16/37] Update uimenu.cpp --- src/uimenu.cpp | 84 +++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 79 insertions(+), 5 deletions(-) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index abaa5c9..e2bcd1e 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -86,16 +86,16 @@ const CUIMenu::TMenuItem CUIMenu::s_EffectsMenu[] = const CUIMenu::TMenuItem CUIMenu::s_EditPitchBenderMenu[] = { - {"Bender Range", EditTGParameter, 0, CMiniDexed::TGParameterPitchBenderRange}, - {"Bender Step", EditTGParameter, 0, CMiniDexed::TGParameterPitchBenderStep}, + {"Bender Range", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBenderRange}, + {"Bender Step", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBenderStep}, {0} }; const CUIMenu::TMenuItem CUIMenu::s_EditPortamentoMenu[] = { - {"Mode", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoMode}, - {"Glissando", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoGlissando}, - {"Time", EditTGParameter, 0, CMiniDexed::TGParameterPortamentoTime}, + {"Mode", EditTGParameter2, 0, CMiniDexed::TGParameterPortamentoMode}, + {"Glissando", EditTGParameter2, 0, CMiniDexed::TGParameterPortamentoGlissando}, + {"Time", EditTGParameter2, 0, CMiniDexed::TGParameterPortamentoTime}, {0} }; @@ -581,6 +581,60 @@ void CUIMenu::EditTGParameter (CUIMenu *pUIMenu, TMenuEvent Event) nValue > rParam.Minimum, nValue < rParam.Maximum); } +void CUIMenu::EditTGParameter2 (CUIMenu *pUIMenu, TMenuEvent Event) // second menu level. Redundant code but in order to not modified original code +{ + + unsigned nTG = pUIMenu->m_nMenuStackParameter[pUIMenu->m_nCurrentMenuDepth-2]; + + CMiniDexed::TTGParameter Param = (CMiniDexed::TTGParameter) pUIMenu->m_nCurrentParameter; + const TParameter &rParam = s_TGParameter[Param]; + + int nValue = pUIMenu->m_pMiniDexed->GetTGParameter (Param, nTG); + + switch (Event) + { + case MenuEventUpdate: + break; + + case MenuEventStepDown: + nValue -= rParam.Increment; + if (nValue < rParam.Minimum) + { + nValue = rParam.Minimum; + } + pUIMenu->m_pMiniDexed->SetTGParameter (Param, nValue, nTG); + break; + + case MenuEventStepUp: + nValue += rParam.Increment; + if (nValue > rParam.Maximum) + { + nValue = rParam.Maximum; + } + pUIMenu->m_pMiniDexed->SetTGParameter (Param, nValue, nTG); + break; + + case MenuEventPressAndStepDown: + case MenuEventPressAndStepUp: + pUIMenu->TGShortcutHandler (Event); + return; + + default: + return; + } + + string TG ("TG"); + TG += to_string (nTG+1); + + string Value = GetTGValueString (Param, pUIMenu->m_pMiniDexed->GetTGParameter (Param, nTG)); + + pUIMenu->m_pUI->DisplayWrite (TG.c_str (), + pUIMenu->m_pParentMenu[pUIMenu->m_nCurrentMenuItem].Name, + Value.c_str (), + nValue > rParam.Minimum, nValue < rParam.Maximum); + +} + void CUIMenu::EditVoiceParameter (CUIMenu *pUIMenu, TMenuEvent Event) { unsigned nTG = pUIMenu->m_nMenuStackParameter[pUIMenu->m_nCurrentMenuDepth-2]; @@ -944,6 +998,26 @@ string CUIMenu::ToOscillatorDetune (int nValue) return Result; } +string CUIMenu::ToPortaMode (int nValue) +{ + switch (nValue) + { + case 0: return "Fingered"; + case 1: return "Full time"; + default: return to_string (nValue); + } +}; + +string CUIMenu::ToPortaGlissando (int nValue) +{ + switch (nValue) + { + case 0: return "Off"; + case 1: return "On"; + default: return to_string (nValue); + } +}; + void CUIMenu::TGShortcutHandler (TMenuEvent Event) { assert (m_nCurrentMenuDepth >= 2); From fc773c9586fdef466e50578cc8527f2b47aaa1c4 Mon Sep 17 00:00:00 2001 From: arsamus Date: Fri, 6 May 2022 17:04:07 -0300 Subject: [PATCH 17/37] Update uimenu.h --- src/uimenu.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/uimenu.h b/src/uimenu.h index ac1dd8e..2a78b46 100644 --- a/src/uimenu.h +++ b/src/uimenu.h @@ -83,6 +83,7 @@ private: static void EditVoiceParameter (CUIMenu *pUIMenu, TMenuEvent Event); static void EditOPParameter (CUIMenu *pUIMenu, TMenuEvent Event); static void SavePerformance (CUIMenu *pUIMenu, TMenuEvent Event); + static void EditTGParameter2 (CUIMenu *pUIMenu, TMenuEvent Event); static std::string GetGlobalValueString (unsigned nParameter, int nValue); static std::string GetTGValueString (unsigned nTGParameter, int nValue); @@ -101,6 +102,8 @@ private: static std::string ToKeyboardCurve (int nValue); static std::string ToOscillatorMode (int nValue); static std::string ToOscillatorDetune (int nValue); + static std::string ToPortaMode (int nValue); + static std::string ToPortaGlissando (int nValue); void TGShortcutHandler (TMenuEvent Event); void OPShortcutHandler (TMenuEvent Event); @@ -134,7 +137,7 @@ private: static const TMenuItem s_SaveMenu[]; static const TMenuItem s_EditPitchBenderMenu[]; static const TMenuItem s_EditPortamentoMenu[]; - + static const TParameter s_GlobalParameter[]; static const TParameter s_TGParameter[]; static const TParameter s_VoiceParameter[]; From e1e111c7b69b20a88ab6b47ea24f0a45d374cf42 Mon Sep 17 00:00:00 2001 From: arsamus Date: Fri, 6 May 2022 17:43:38 -0300 Subject: [PATCH 18/37] Update uimenu.cpp --- src/uimenu.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index e2bcd1e..801f4df 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -206,8 +206,8 @@ const CUIMenu::TParameter CUIMenu::s_TGParameter[CMiniDexed::TGParameterUnknown] {0, 99, 1}, // TGParameterReverbSend {0, 12, 1}, // TGParameterPitchBenderRange {0, 12, 1}, // TGParameterPitchBenderStep - {0, 1, 1}, // TGParameterPortamentoMode - {0, 1, 1}, // TGParameterPortamentoGlissando + {0, 1, 1, ToPortaMode}, // TGParameterPortamentoMode + {0, 1, 1, ToPortaGlissando}, // TGParameterPortamentoGlissando {0, 99, 1} // TGParameterPortamentoTime }; From 401ea2f8182467cad53d21e3d9731a9af20fa879 Mon Sep 17 00:00:00 2001 From: arsamus Date: Mon, 9 May 2022 17:54:37 -0300 Subject: [PATCH 19/37] Update minidexed.cpp --- src/minidexed.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 8a41417..118f106 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -479,8 +479,8 @@ void CMiniDexed::SetPortaMode (uint8_t nValue, unsigned nTG) m_nPortamentoMode[nTG] = nValue; assert (m_pTG[nTG]); - // m_pTG[nTG]->setPortamentoMode (nValue); // uncoment and comment following in news version of dexed - m_pTG[nTG]->setPortamentoMode (nValue, m_nPortamentoGlissando[nTG], m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_pTG[nTG]->setPortamentoMode (nValue); // uncoment and comment following in news version of dexed + //m_pTG[nTG]->setPortamentoMode (nValue, m_nPortamentoGlissando[nTG], m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this m_UI.ParameterChanged (); } @@ -493,8 +493,8 @@ void CMiniDexed::SetPortaGlissando (uint8_t nValue, unsigned nTG) m_nPortamentoGlissando[nTG] = nValue; assert (m_pTG[nTG]); - // m_pTG[nTG]->setPortamentoGlissando (nValue); // uncoment and comment following in news version of dexed - m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], nValue, m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_pTG[nTG]->setPortamentoGlissando (nValue); // uncoment and comment following in news version of dexed + //m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], nValue, m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this m_UI.ParameterChanged (); } @@ -507,8 +507,8 @@ void CMiniDexed::SetPortaTime (uint8_t nValue, unsigned nTG) m_nPortamentoTime[nTG] = nValue; assert (m_pTG[nTG]); - // m_pTG[nTG]->setPortamentoTime (nValue); // uncoment and comment following in news version of dexed - m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], m_nPortamentoGlissando[nTG], nValue); // Compile error due to new implementation in Dexed, uncoment above and coment this + m_pTG[nTG]->setPortamentoTime (nValue); // uncoment and comment following in news version of dexed + //m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], m_nPortamentoGlissando[nTG], nValue); // Compile error due to new implementation in Dexed, uncoment above and coment this m_UI.ParameterChanged (); } From 139e7c787157c01491541bc0f340a4659b500dc4 Mon Sep 17 00:00:00 2001 From: arsamus Date: Tue, 10 May 2022 09:58:46 -0300 Subject: [PATCH 20/37] Update serialmididevice.cpp --- src/serialmididevice.cpp | 116 +++++++++++++++++++++------------------ 1 file changed, 62 insertions(+), 54 deletions(-) diff --git a/src/serialmididevice.cpp b/src/serialmididevice.cpp index 6c484cf..3ad7d2a 100644 --- a/src/serialmididevice.cpp +++ b/src/serialmididevice.cpp @@ -83,70 +83,78 @@ void CSerialMIDIDevice::Process (void) { u8 uchData = Buffer[i]; - if(uchData == 0xF0) + switch (m_nSerialState) { - // SYSEX found - m_SerialMessage[m_nSysEx++]=uchData; - continue; - } + case 0: + MIDIRestart: + if ( (uchData & 0x80) == 0x80 // status byte, all channels + && (uchData & 0xF0) != 0xF0) // ignore system messages + { + m_SerialMessage[m_nSerialState++] = uchData; + } + + if (uchData == 0xF0) // SysEx status Byte jumps to m_nSerialState=5 and iniciate reading + { + m_nSerialState = 5; + m_nSysEx = 0; + goto MIDISysEx; + } + + break; - if(m_nSysEx > 0) - { - m_SerialMessage[m_nSysEx++]=uchData; - if ((uchData & 0x80) == 0x80 || m_nSysEx >= MAX_MIDI_MESSAGE) + case 1: + case 2: + DATABytes: + if (uchData & 0x80) // got status when parameter expected { - if(uchData == 0xF7) - MIDIMessageHandler (m_SerialMessage, m_nSysEx); - m_nSysEx = 0; + m_nSerialState = 0; + + goto MIDIRestart; } - continue; - } - else - { - switch (m_nSerialState) + + m_SerialMessage[m_nSerialState++] = uchData; + + if ( (m_SerialMessage[0] & 0xE0) == 0xC0 + || m_nSerialState == 3) // message is complete { - case 0: - MIDIRestart: - if ( (uchData & 0x80) == 0x80 // status byte, all channels - && (uchData & 0xF0) != 0xF0) // ignore system messages - { - m_SerialMessage[m_nSerialState++] = uchData; - } - break; - - case 1: - case 2: - DATABytes: - if (uchData & 0x80) // got status when parameter expected - { - m_nSerialState = 0; - - goto MIDIRestart; - } - - m_SerialMessage[m_nSerialState++] = uchData; - - if ( (m_SerialMessage[0] & 0xE0) == 0xC0 - || m_nSerialState == 3) // message is complete + MIDIMessageHandler (m_SerialMessage, m_nSerialState); + + m_nSerialState = 4; // State 4 for test if 4th byte is a status byte or a data byte + } + break; + case 4: // Running Status evaluation + + if ((uchData & 0x80) == 0) // true data byte, false status byte + { + m_nSerialState = 1; // Byte 0 not change on Running Status + goto DATABytes; + } + else + { + m_nSerialState = 0; + goto MIDIRestart; // This is necessary in order to not miss the first byte + + } + break; + case 5: // SyxEx reading + MIDISysEx: + m_SerialMessage[m_nSysEx++] = uchData; + if (((uchData & 0x80) && m_nSysEx > 1 ) || m_nSysEx >= MAX_MIDI_MESSAGE) + { + m_nSerialState = 0; //New Status byte ends SerialState 5 (SysEx reading) + if (uchData == 0xF7) { - MIDIMessageHandler (m_SerialMessage, m_nSerialState); - - m_nSerialState = 4; // State 4 for test if 4th byte is a status byte or a data byte + MIDIMessageHandler (m_SerialMessage, m_nSysEx); } - - break; - case 4: - - if ((uchData & 0x80) == 0) // true data byte, false status byte + else { - m_nSerialState = 1; - goto DATABytes; + goto MIDIRestart; //other status byte abort SysEx process and jump to MIDIRestart in order to not miss the byte } - break; - default: - assert (0); - break; } + break; + default: + assert (0); + break; } } } From cedeeb33dca40b2186b816f3d2281b71ec46f4d2 Mon Sep 17 00:00:00 2001 From: arsamus Date: Thu, 12 May 2022 16:55:29 -0300 Subject: [PATCH 21/37] Update serialmididevice.cpp --- src/serialmididevice.cpp | 120 +++++++++++++++++++-------------------- 1 file changed, 58 insertions(+), 62 deletions(-) diff --git a/src/serialmididevice.cpp b/src/serialmididevice.cpp index fa43715..ec819d0 100644 --- a/src/serialmididevice.cpp +++ b/src/serialmididevice.cpp @@ -85,82 +85,78 @@ void CSerialMIDIDevice::Process (void) { u8 uchData = Buffer[i]; - switch (m_nSerialState) + if(uchData == 0xF0) { - case 0: - MIDIRestart: - if ( (uchData & 0x80) == 0x80 // status byte, all channels - && (uchData & 0xF0) != 0xF0) // ignore system messages - { - m_SerialMessage[m_nSerialState++] = uchData; - } - - if (uchData == 0xF0) // SysEx status Byte jumps to m_nSerialState=5 and iniciate reading - { - m_nSerialState = 5; - m_nSysEx = 0; - goto MIDISysEx; - } - - break; - - case 1: - case 2: - DATABytes: - if (uchData & 0x80) // got status when parameter expected - { - m_nSerialState = 0; - - goto MIDIRestart; - } - - m_SerialMessage[m_nSerialState++] = uchData; - - if ( (m_SerialMessage[0] & 0xE0) == 0xC0 - || m_nSerialState == 3) // message is complete - { - MIDIMessageHandler (m_SerialMessage, m_nSerialState); + // SYSEX found + m_SerialMessage[m_nSysEx++]=uchData; + continue; + } - m_nSerialState = 4; // State 4 for test if 4th byte is a status byte or a data byte - } - break; - case 4: // Running Status evaluation - - if ((uchData & 0x80) == 0) // true data byte, false status byte + if(m_nSysEx > 0) + { + m_SerialMessage[m_nSysEx++]=uchData; + if ((uchData & 0x80) == 0x80 || m_nSysEx >= MAX_MIDI_MESSAGE) { - m_nSerialState = 1; // Byte 0 not change on Running Status - goto DATABytes; + if(uchData == 0xF7) + MIDIMessageHandler (m_SerialMessage, m_nSysEx); + m_nSysEx = 0; } - else + continue; + } + else + { + switch (m_nSerialState) { - m_nSerialState = 0; - goto MIDIRestart; // This is necessary in order to not miss the first byte + case 0: + MIDIRestart: + if ( (uchData & 0x80) == 0x80 // status byte, all channels + && (uchData & 0xF0) != 0xF0) // ignore system messages + { + m_SerialMessage[m_nSerialState++] = uchData; + } + break; + + case 1: + case 2: + DATABytes: + if (uchData & 0x80) // got status when parameter expected + { + m_nSerialState = 0; + + goto MIDIRestart; + } + + m_SerialMessage[m_nSerialState++] = uchData; + + if ( (m_SerialMessage[0] & 0xE0) == 0xC0 + || m_nSerialState == 3) // message is complete + { + MIDIMessageHandler (m_SerialMessage, m_nSerialState); + + m_nSerialState = 4; // State 4 for test if 4th byte is a status byte or a data byte + } + + break; + case 4: - } - break; - case 5: // SyxEx reading - MIDISysEx: - m_SerialMessage[m_nSysEx++] = uchData; - if (((uchData & 0x80) && m_nSysEx > 1 ) || m_nSysEx >= MAX_MIDI_MESSAGE) - { - m_nSerialState = 0; //New Status byte ends SerialState 5 (SysEx reading) - if (uchData == 0xF7) + if ((uchData & 0x80) == 0) // true data byte, false status byte { - MIDIMessageHandler (m_SerialMessage, m_nSysEx); + m_nSerialState = 1; + goto DATABytes; } - else + else { - goto MIDIRestart; //other status byte abort SysEx process and jump to MIDIRestart in order to not miss the byte + m_nSerialState = 0; + goto MIDIRestart; } + break; + default: + assert (0); + break; } - break; - default: - assert (0); - break; } } } - void CSerialMIDIDevice::Send (const u8 *pMessage, size_t nLength, unsigned nCable) { m_SendBuffer.Write (pMessage, nLength); From 3fe74b7eef26f7e2f65c4e54eddcfcd68dab20e9 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 14:39:36 -0300 Subject: [PATCH 22/37] Update performance.ini --- src/performance.ini | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/src/performance.ini b/src/performance.ini index 843f9d5..bdd3d66 100644 --- a/src/performance.ini +++ b/src/performance.ini @@ -15,8 +15,8 @@ #NoteLimitHigh#=127 # 0 .. 127, C-2 .. G8 #NoteShift#=0 # -24 .. 24 #ReverbSend#=0 # 0 .. 99 -#PitchBenderRange#=2 # 0 .. 12 -#PitchBenderStep#=0 # 0 .. 12 +#PitchBendRange#=2 # 0 .. 12 +#PitchBendStep#=0 # 0 .. 12 #PortamentoMode#=0 # 0 .. 1 #PortamentoGlissando#=0 # 0 .. 1 #PortamentoTime#=0 # 0 .. 99 @@ -34,8 +34,8 @@ NoteLimitLow1=0 NoteLimitHigh1=127 NoteShift1=0 ReverbSend1=99 -PitchBenderRange1=2 -PitchBenderStep1=0 +PitchBendRange1=2 +PitchBendStep1=0 PortamentoMode1=0 PortamentoGlissando1=0 PortamentoTime1=0 @@ -53,8 +53,8 @@ NoteLimitLow2=0 NoteLimitHigh2=127 NoteShift2=0 ReverbSend2=70 -PitchBenderRange2=2 -PitchBenderStep2=0 +PitchBendRange2=2 +PitchBendStep2=0 PortamentoMode2=0 PortamentoGlissando2=0 PortamentoTime2=0 @@ -72,8 +72,8 @@ NoteLimitLow3=0 NoteLimitHigh3=127 NoteShift3=0 ReverbSend3=0 -PitchBenderRange3=2 -PitchBenderStep3=0 +PitchBendRange3=2 +PitchBendStep3=0 PortamentoMode3=0 PortamentoGlissando3=0 PortamentoTime3=0 @@ -91,8 +91,8 @@ NoteLimitLow4=0 NoteLimitHigh4=127 NoteShift4=0 ReverbSend4=0 -PitchBenderRange4=2 -PitchBenderStep4=0 +PitchBendRange4=2 +PitchBendStep4=0 PortamentoMode4=0 PortamentoGlissando4=0 PortamentoTime4=0 @@ -110,8 +110,8 @@ NoteLimitLow5=0 NoteLimitHigh5=127 NoteShift5=0 ReverbSend5=0 -PitchBenderRange5=2 -PitchBenderStep5=0 +PitchBendRange5=2 +PitchBendStep5=0 PortamentoMode5=0 PortamentoGlissando5=0 PortamentoTime5=0 @@ -129,8 +129,8 @@ NoteLimitLow6=0 NoteLimitHigh6=127 NoteShift6=0 ReverbSend6=0 -PitchBenderRange6=2 -PitchBenderStep6=0 +PitchBendRange6=2 +PitchBendStep6=0 PortamentoMode6=0 PortamentoGlissando6=0 PortamentoTime6=0 @@ -148,8 +148,8 @@ NoteLimitLow7=0 NoteLimitHigh7=127 NoteShift7=0 ReverbSend7=0 -PitchBenderRange7=2 -PitchBenderStep7=0 +PitchBendRange7=2 +PitchBendStep7=0 PortamentoMode7=0 PortamentoGlissando7=0 PortamentoTime7=0 @@ -167,8 +167,8 @@ NoteLimitLow8=0 NoteLimitHigh8=127 NoteShift8=0 ReverbSend8=0 -PitchBenderRange8=2 -PitchBenderStep8=0 +PitchBendRange8=2 +PitchBendStep8=0 PortamentoMode8=0 PortamentoGlissando8=0 PortamentoTime8=0 From 2dcf401bf7783e7f40c1cf3dd45b3c17920f818c Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 14:41:08 -0300 Subject: [PATCH 23/37] Update performanceconfig.h --- src/performanceconfig.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/performanceconfig.h b/src/performanceconfig.h index 8b5887f..bf7617a 100644 --- a/src/performanceconfig.h +++ b/src/performanceconfig.h @@ -50,8 +50,8 @@ public: unsigned GetNoteLimitHigh (unsigned nTG) const; // 0 .. 127 int GetNoteShift (unsigned nTG) const; // -24 .. 24 unsigned GetReverbSend (unsigned nTG) const; // 0 .. 127 - unsigned GetPitchBenderRange (unsigned nTG) const; // 0 .. 12 - unsigned GetPitchBenderStep (unsigned nTG) const; // 0 .. 12 + unsigned GetPitchBendRange (unsigned nTG) const; // 0 .. 12 + unsigned GetPitchBendStep (unsigned nTG) const; // 0 .. 12 unsigned GetPortamentoMode (unsigned nTG) const; // 0 .. 1 unsigned GetPortamentoGlissando (unsigned nTG) const; // 0 .. 1 unsigned GetPortamentoTime (unsigned nTG) const; // 0 .. 99 @@ -68,8 +68,8 @@ public: void SetNoteLimitHigh (unsigned nValue, unsigned nTG); void SetNoteShift (int nValue, unsigned nTG); void SetReverbSend (unsigned nValue, unsigned nTG); - void SetPitchBenderRange (unsigned nValue, unsigned nTG); - void SetPitchBenderStep (unsigned nValue, unsigned nTG); + void SetPitchBendRange (unsigned nValue, unsigned nTG); + void SetPitchBendStep (unsigned nValue, unsigned nTG); void SetPortamentoMode (unsigned nValue, unsigned nTG); void SetPortamentoGlissando (unsigned nValue, unsigned nTG); void SetPortamentoTime (unsigned nValue, unsigned nTG); @@ -108,8 +108,8 @@ private: unsigned m_nNoteLimitHigh[CConfig::ToneGenerators]; int m_nNoteShift[CConfig::ToneGenerators]; int m_nReverbSend[CConfig::ToneGenerators]; - unsigned m_nPitchBenderRange[CConfig::ToneGenerators]; - unsigned m_nPitchBenderStep[CConfig::ToneGenerators]; + unsigned m_nPitchBendRange[CConfig::ToneGenerators]; + unsigned m_nPitchBendStep[CConfig::ToneGenerators]; unsigned m_nPortamentoMode[CConfig::ToneGenerators]; unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; unsigned m_nPortamentoTime[CConfig::ToneGenerators]; From 3be37695d1191fe0fe632f7974850ebfa9fb0b0c Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 14:43:58 -0300 Subject: [PATCH 24/37] Update performanceconfig.cpp --- src/performanceconfig.cpp | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/performanceconfig.cpp b/src/performanceconfig.cpp index a92b148..558502f 100644 --- a/src/performanceconfig.cpp +++ b/src/performanceconfig.cpp @@ -99,10 +99,10 @@ bool CPerformanceConfig::Load (void) PropertyName.Format ("ReverbSend%u", nTG+1); m_nReverbSend[nTG] = m_Properties.GetNumber (PropertyName, 50); - PropertyName.Format ("PitchBenderRange%u", nTG+1); + PropertyName.Format ("PitchBendRange%u", nTG+1); m_nPitchBenderRange[nTG] = m_Properties.GetNumber (PropertyName, 2); - PropertyName.Format ("PitchBenderStep%u", nTG+1); + PropertyName.Format ("PitchBendStep%u", nTG+1); m_nPitchBenderStep[nTG] = m_Properties.GetNumber (PropertyName, 0); PropertyName.Format ("PortamentoMode%u", nTG+1); @@ -185,11 +185,11 @@ bool CPerformanceConfig::Save (void) PropertyName.Format ("ReverbSend%u", nTG+1); m_Properties.SetNumber (PropertyName, m_nReverbSend[nTG]); - PropertyName.Format ("PitchBenderRange%u", nTG+1); - m_Properties.SetNumber (PropertyName, m_nPitchBenderRange[nTG]); + PropertyName.Format ("PitchBendRange%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPitchBendRange[nTG]); - PropertyName.Format ("PitchBenderStep%u", nTG+1); - m_Properties.SetNumber (PropertyName, m_nPitchBenderStep[nTG]); + PropertyName.Format ("PitchBendStep%u", nTG+1); + m_Properties.SetNumber (PropertyName, m_nPitchBendStep[nTG]); PropertyName.Format ("PortamentoMode%u", nTG+1); m_Properties.SetNumber (PropertyName, m_nPortamentoMode[nTG]); @@ -438,29 +438,29 @@ void CPerformanceConfig::SetReverbLevel (unsigned nValue) m_nReverbLevel = nValue; } // Pitch bender and portamento: -void CPerformanceConfig::SetPitchBenderRange (unsigned nValue, unsigned nTG) +void CPerformanceConfig::SetPitchBendRange (unsigned nValue, unsigned nTG) { assert (nTG < CConfig::ToneGenerators); - m_nPitchBenderRange[nTG] = nValue; + m_nPitchBendRange[nTG] = nValue; } -unsigned CPerformanceConfig::GetPitchBenderRange (unsigned nTG) const +unsigned CPerformanceConfig::GetPitchBendRange (unsigned nTG) const { assert (nTG < CConfig::ToneGenerators); - return m_nPitchBenderRange[nTG]; + return m_nPitchBendRange[nTG]; } -void CPerformanceConfig::SetPitchBenderStep (unsigned nValue, unsigned nTG) +void CPerformanceConfig::SetPitchBendStep (unsigned nValue, unsigned nTG) { assert (nTG < CConfig::ToneGenerators); - m_nPitchBenderStep[nTG] = nValue; + m_nPitchBendStep[nTG] = nValue; } -unsigned CPerformanceConfig::GetPitchBenderStep (unsigned nTG) const +unsigned CPerformanceConfig::GetPitchBendStep (unsigned nTG) const { assert (nTG < CConfig::ToneGenerators); - return m_nPitchBenderStep[nTG]; + return m_nPitchBendStep[nTG]; } From 0d6a8a9c0ae1286c6b9d4bb3b17ddb343325374a Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 14:45:04 -0300 Subject: [PATCH 25/37] Update performanceconfig.cpp --- src/performanceconfig.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/performanceconfig.cpp b/src/performanceconfig.cpp index 558502f..5c381ec 100644 --- a/src/performanceconfig.cpp +++ b/src/performanceconfig.cpp @@ -100,10 +100,10 @@ bool CPerformanceConfig::Load (void) m_nReverbSend[nTG] = m_Properties.GetNumber (PropertyName, 50); PropertyName.Format ("PitchBendRange%u", nTG+1); - m_nPitchBenderRange[nTG] = m_Properties.GetNumber (PropertyName, 2); + m_nPitchBendRange[nTG] = m_Properties.GetNumber (PropertyName, 2); PropertyName.Format ("PitchBendStep%u", nTG+1); - m_nPitchBenderStep[nTG] = m_Properties.GetNumber (PropertyName, 0); + m_nPitchBendStep[nTG] = m_Properties.GetNumber (PropertyName, 0); PropertyName.Format ("PortamentoMode%u", nTG+1); m_nPortamentoMode[nTG] = m_Properties.GetNumber (PropertyName, 0); From 801f8b27d88fe788781b00935a71d3c62b8418f6 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:00:14 -0300 Subject: [PATCH 26/37] Update minidexed.cpp --- src/minidexed.cpp | 126 +++++++++++++--------------------------------- 1 file changed, 35 insertions(+), 91 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 4b65c3b..4ae583d 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -63,8 +63,8 @@ CMiniDexed::CMiniDexed (CConfig *pConfig, CInterruptSystem *pInterrupt, m_nCutoff[i] = 99; m_nResonance[i] = 0; m_nMIDIChannel[i] = CMIDIDevice::Disabled; - m_nPitchBenderRange[i] = 2; - m_nPitchBenderStep[i] = 0; + m_nPitchBendRange[i] = 2; + m_nPitchBendStep[i] = 0; m_nPortamentoMode[i] = 0; m_nPortamentoGlissando[i] = 0; m_nPortamentoTime[i] = 0; @@ -192,11 +192,11 @@ bool CMiniDexed::Initialize (void) SetMasterTune (m_PerformanceConfig.GetDetune (nTG), nTG); SetCutoff (m_PerformanceConfig.GetCutoff (nTG), nTG); SetResonance (m_PerformanceConfig.GetResonance (nTG), nTG); - SetPitchBenderRange (m_PerformanceConfig.GetPitchBenderRange (nTG), nTG); - SetPitchBenderStep (m_PerformanceConfig.GetPitchBenderStep (nTG), nTG); - SetPortaMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); - SetPortaGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); - SetPortaTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); + SetPitchBendRange (m_PerformanceConfig.GetPitchBendRange (nTG), nTG); + SetPitchBendStep (m_PerformanceConfig.GetPitchBendStep (nTG), nTG); + SetPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); + SetPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); + SetPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); m_nNoteLimitLow[nTG] = m_PerformanceConfig.GetNoteLimitLow (nTG); m_nNoteLimitHigh[nTG] = m_PerformanceConfig.GetNoteLimitHigh (nTG); @@ -444,73 +444,6 @@ void CMiniDexed::SetResonance (int nResonance, unsigned nTG) m_UI.ParameterChanged (); } -void CMiniDexed::SetPitchBenderRange (uint8_t nValue, unsigned nTG) -{ - nValue = constrain (nValue, 0, 12); - - assert (nTG < CConfig::ToneGenerators); - m_nPitchBenderRange[nTG] = nValue; - - assert (m_pTG[nTG]); - m_pTG[nTG]->setPitchbendRange (nValue); - - m_UI.ParameterChanged (); -} - -void CMiniDexed::SetPitchBenderStep (uint8_t nValue, unsigned nTG) -{ - nValue= constrain (nValue, 0, 12); - - assert (nTG < CConfig::ToneGenerators); - m_nPitchBenderStep[nTG] = nValue; - - assert (m_pTG[nTG]); - m_pTG[nTG]->setPitchbendStep (nValue); - - m_UI.ParameterChanged (); -} - -void CMiniDexed::SetPortaMode (uint8_t nValue, unsigned nTG) -{ - nValue= constrain (nValue, 0, 1); - - assert (nTG < CConfig::ToneGenerators); - m_nPortamentoMode[nTG] = nValue; - - assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoMode (nValue); // uncoment and comment following in news version of dexed - //m_pTG[nTG]->setPortamentoMode (nValue, m_nPortamentoGlissando[nTG], m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this - - m_UI.ParameterChanged (); -} - -void CMiniDexed::SetPortaGlissando (uint8_t nValue, unsigned nTG) -{ - nValue = constrain (nValue, 0, 1); - - assert (nTG < CConfig::ToneGenerators); - m_nPortamentoGlissando[nTG] = nValue; - - assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoGlissando (nValue); // uncoment and comment following in news version of dexed - //m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], nValue, m_nPortamentoTime[nTG]); // Compile error due to new implementation in Dexed, uncoment above and coment this - - m_UI.ParameterChanged (); -} - -void CMiniDexed::SetPortaTime (uint8_t nValue, unsigned nTG) -{ - nValue = constrain (nValue, 0, 99); - - assert (nTG < CConfig::ToneGenerators); - m_nPortamentoTime[nTG] = nValue; - - assert (m_pTG[nTG]); - m_pTG[nTG]->setPortamentoTime (nValue); // uncoment and comment following in news version of dexed - //m_pTG[nTG]->setPortamentoMode (m_nPortamentoMode[nTG], m_nPortamentoGlissando[nTG], nValue); // Compile error due to new implementation in Dexed, uncoment above and coment this - - m_UI.ParameterChanged (); -} void CMiniDexed::SetMIDIChannel (uint8_t uchChannel, unsigned nTG) @@ -731,11 +664,11 @@ void CMiniDexed::SetTGParameter (TTGParameter Parameter, int nValue, unsigned nT case TGParameterMasterTune: SetMasterTune (nValue, nTG); break; case TGParameterCutoff: SetCutoff (nValue, nTG); break; case TGParameterResonance: SetResonance (nValue, nTG); break; - case TGParameterPitchBenderRange: SetPitchBenderRange (nValue, nTG); break; - case TGParameterPitchBenderStep: SetPitchBenderStep (nValue, nTG); break; - case TGParameterPortamentoMode: SetPortaMode (nValue, nTG); break; - case TGParameterPortamentoGlissando: SetPortaGlissando (nValue, nTG); break; - case TGParameterPortamentoTime: SetPortaTime (nValue, nTG); break; + case TGParameterPitchBendRange: SetPitchBendRange (nValue, nTG); break; + case TGParameterPitchBendStep: SetPitchBendStep (nValue, nTG); break; + case TGParameterPortamentoMode: SetPortamentoMode (nValue, nTG); break; + case TGParameterPortamentoGlissando: SetPortamentoGlissando (nValue, nTG); break; + case TGParameterPortamentoTime: SetPortamentoTime (nValue, nTG); break; case TGParameterMIDIChannel: assert (0 <= nValue && nValue <= 255); @@ -1011,8 +944,8 @@ bool CMiniDexed::SavePerformance (void) m_PerformanceConfig.SetDetune (m_nMasterTune[nTG], nTG); m_PerformanceConfig.SetCutoff (m_nCutoff[nTG], nTG); m_PerformanceConfig.SetResonance (m_nResonance[nTG], nTG); - m_PerformanceConfig.SetPitchBenderRange (m_nPitchBenderRange[nTG], nTG); - m_PerformanceConfig.SetPitchBenderStep (m_nPitchBenderStep[nTG], nTG); + m_PerformanceConfig.SetPitchBendRange (m_nPitchBendRange[nTG], nTG); + m_PerformanceConfig.SetPitchBendStep (m_nPitchBendStep[nTG], nTG); m_PerformanceConfig.SetPortamentoMode (m_nPortamentoMode[nTG], nTG); m_PerformanceConfig.SetPortamentoGlissando (m_nPortamentoGlissando[nTG], nTG); m_PerformanceConfig.SetPortamentoTime (m_nPortamentoTime[nTG], nTG); @@ -1048,50 +981,61 @@ void CMiniDexed::setMonoMode(uint8_t mono, uint8_t nTG) void CMiniDexed::setPitchbendRange(uint8_t range, uint8_t nTG) { + range = constrain (range, 0, 12); assert (nTG < CConfig::ToneGenerators); assert (m_pTG[nTG]); - - m_pTG[nTG]->setPitchbendRange(constrain(range, 0, 12)); + m_nPitchBendRange[nTG] = range; + + m_pTG[nTG]->setPitchbendRange(range); m_pTG[nTG]->ControllersRefresh(); m_UI.ParameterChanged (); } void CMiniDexed::setPitchbendStep(uint8_t step, uint8_t nTG) { + step= constrain (step, 0, 12); assert (nTG < CConfig::ToneGenerators); assert (m_pTG[nTG]); - - m_pTG[nTG]->setPitchbendStep(constrain(step, 0, 12)); + m_nPitchBendStep[nTG] = step; + + m_pTG[nTG]->setPitchbendStep(step); m_pTG[nTG]->ControllersRefresh(); m_UI.ParameterChanged (); } void CMiniDexed::setPortamentoMode(uint8_t mode, uint8_t nTG) { + mode= constrain (mode, 0, 1); + assert (nTG < CConfig::ToneGenerators); assert (m_pTG[nTG]); - - m_pTG[nTG]->setPortamentoMode(constrain(mode, 0, 1)); + m_nPortamentoMode[nTG] = mode; + + m_pTG[nTG]->setPortamentoMode(mode); m_pTG[nTG]->ControllersRefresh(); m_UI.ParameterChanged (); } void CMiniDexed::setPortamentoGlissando(uint8_t glissando, uint8_t nTG) { + glissando = constrain (glissando, 0, 1); assert (nTG < CConfig::ToneGenerators); assert (m_pTG[nTG]); - - m_pTG[nTG]->setPortamentoGlissando(constrain(glissando, 0, 1)); + m_nPortamentoGlissando[nTG] = glissando; + + m_pTG[nTG]->setPortamentoGlissando(glissando); m_pTG[nTG]->ControllersRefresh(); m_UI.ParameterChanged (); } void CMiniDexed::setPortamentoTime(uint8_t time, uint8_t nTG) { + time = constrain (time, 0, 99); assert (nTG < CConfig::ToneGenerators); assert (m_pTG[nTG]); - - m_pTG[nTG]->setPortamentoTime(constrain(time, 0, 99)); + m_nPortamentoTime[nTG] = time; + + m_pTG[nTG]->setPortamentoTime(time); m_pTG[nTG]->ControllersRefresh(); m_UI.ParameterChanged (); } From ae2b5a72903bc54d4c80017bc7dc51cfa2f0f559 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:01:18 -0300 Subject: [PATCH 27/37] Update minidexed.cpp --- src/minidexed.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 4ae583d..52f28f8 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -698,8 +698,8 @@ int CMiniDexed::GetTGParameter (TTGParameter Parameter, unsigned nTG) case TGParameterResonance: return m_nResonance[nTG]; case TGParameterMIDIChannel: return m_nMIDIChannel[nTG]; case TGParameterReverbSend: return m_nReverbSend[nTG]; - case TGParameterPitchBenderRange: return m_nPitchBenderRange[nTG]; - case TGParameterPitchBenderStep: return m_nPitchBenderStep[nTG]; + case TGParameterPitchBendRange: return m_nPitchBendRange[nTG]; + case TGParameterPitchBendStep: return m_nPitchBendStep[nTG]; case TGParameterPortamentoMode: return m_nPortamentoMode[nTG]; case TGParameterPortamentoGlissando: return m_nPortamentoGlissando[nTG]; case TGParameterPortamentoTime: return m_nPortamentoTime[nTG]; From 949986dad202b41ee4a56a81674770ca166d9419 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:05:40 -0300 Subject: [PATCH 28/37] Update minidexed.h --- src/minidexed.h | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/minidexed.h b/src/minidexed.h index 463db6a..66beb35 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -71,11 +71,6 @@ public: void SetCutoff (int nCutoff, unsigned nTG); // 0 .. 99 void SetResonance (int nResonance, unsigned nTG); // 0 .. 99 void SetMIDIChannel (uint8_t uchChannel, unsigned nTG); - void SetPitchBenderRange (uint8_t nValue, unsigned nTG); - void SetPitchBenderStep (uint8_t nValue, unsigned nTG); - void SetPortaMode (uint8_t nValue, unsigned nTG); - void SetPortaGlissando (uint8_t nValue, unsigned nTG); - void SetPortaTime (uint8_t nValue, unsigned nTG); void keyup (int16_t pitch, unsigned nTG); void keydown (int16_t pitch, uint8_t velocity, unsigned nTG); @@ -135,8 +130,8 @@ public: TGParameterResonance, TGParameterMIDIChannel, TGParameterReverbSend, - TGParameterPitchBenderRange, - TGParameterPitchBenderStep, + TGParameterPitchBendRange, + TGParameterPitchBendStep, TGParameterPortamentoMode, TGParameterPortamentoGlissando, TGParameterPortamentoTime, @@ -187,8 +182,8 @@ private: int m_nCutoff[CConfig::ToneGenerators]; int m_nResonance[CConfig::ToneGenerators]; unsigned m_nMIDIChannel[CConfig::ToneGenerators]; - unsigned m_nPitchBenderRange[CConfig::ToneGenerators]; - unsigned m_nPitchBenderStep[CConfig::ToneGenerators]; + unsigned m_nPitchBendRange[CConfig::ToneGenerators]; + unsigned m_nPitchBendStep[CConfig::ToneGenerators]; unsigned m_nPortamentoMode[CConfig::ToneGenerators]; unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; unsigned m_nPortamentoTime[CConfig::ToneGenerators]; From 0af2da2f9a306c5064b4e8fc8979970a7fb5c249 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:09:16 -0300 Subject: [PATCH 29/37] Update minidexed.cpp --- src/minidexed.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 52f28f8..dc61660 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -192,8 +192,8 @@ bool CMiniDexed::Initialize (void) SetMasterTune (m_PerformanceConfig.GetDetune (nTG), nTG); SetCutoff (m_PerformanceConfig.GetCutoff (nTG), nTG); SetResonance (m_PerformanceConfig.GetResonance (nTG), nTG); - SetPitchBendRange (m_PerformanceConfig.GetPitchBendRange (nTG), nTG); - SetPitchBendStep (m_PerformanceConfig.GetPitchBendStep (nTG), nTG); + SetPitchbendRange (m_PerformanceConfig.GetPitchBendRange (nTG), nTG); + SetPitchbendStep (m_PerformanceConfig.GetPitchBendStep (nTG), nTG); SetPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); SetPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); SetPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); @@ -664,8 +664,8 @@ void CMiniDexed::SetTGParameter (TTGParameter Parameter, int nValue, unsigned nT case TGParameterMasterTune: SetMasterTune (nValue, nTG); break; case TGParameterCutoff: SetCutoff (nValue, nTG); break; case TGParameterResonance: SetResonance (nValue, nTG); break; - case TGParameterPitchBendRange: SetPitchBendRange (nValue, nTG); break; - case TGParameterPitchBendStep: SetPitchBendStep (nValue, nTG); break; + case TGParameterPitchBendRange: SetPitchbendRange (nValue, nTG); break; + case TGParameterPitchBendStep: SetPitchbendStep (nValue, nTG); break; case TGParameterPortamentoMode: SetPortamentoMode (nValue, nTG); break; case TGParameterPortamentoGlissando: SetPortamentoGlissando (nValue, nTG); break; case TGParameterPortamentoTime: SetPortamentoTime (nValue, nTG); break; From 92a9c50ded936b2e3ee33371997746136e9b1e07 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:15:25 -0300 Subject: [PATCH 30/37] Update uimenu.cpp --- src/uimenu.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/uimenu.cpp b/src/uimenu.cpp index 801f4df..c12bd39 100644 --- a/src/uimenu.cpp +++ b/src/uimenu.cpp @@ -68,7 +68,7 @@ const CUIMenu::TMenuItem CUIMenu::s_TGMenu[] = {"Detune", EditTGParameter, 0, CMiniDexed::TGParameterMasterTune}, {"Cutoff", EditTGParameter, 0, CMiniDexed::TGParameterCutoff}, {"Resonance", EditTGParameter, 0, CMiniDexed::TGParameterResonance}, - {"Pitch Bender", MenuHandler, s_EditPitchBenderMenu}, + {"Pitch Bend", MenuHandler, s_EditPitchBendMenu}, {"Portamento", MenuHandler, s_EditPortamentoMenu}, {"Channel", EditTGParameter, 0, CMiniDexed::TGParameterMIDIChannel}, {"Edit Voice", MenuHandler, s_EditVoiceMenu}, @@ -84,10 +84,10 @@ const CUIMenu::TMenuItem CUIMenu::s_EffectsMenu[] = {0} }; -const CUIMenu::TMenuItem CUIMenu::s_EditPitchBenderMenu[] = +const CUIMenu::TMenuItem CUIMenu::s_EditPitchBendMenu[] = { - {"Bender Range", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBenderRange}, - {"Bender Step", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBenderStep}, + {"Bend Range", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBendRange}, + {"Bend Step", EditTGParameter2, 0, CMiniDexed::TGParameterPitchBendStep}, {0} }; @@ -204,8 +204,8 @@ const CUIMenu::TParameter CUIMenu::s_TGParameter[CMiniDexed::TGParameterUnknown] {0, 99, 1}, // TGParameterResonance {0, CMIDIDevice::ChannelUnknown-1, 1, ToMIDIChannel}, // TGParameterMIDIChannel {0, 99, 1}, // TGParameterReverbSend - {0, 12, 1}, // TGParameterPitchBenderRange - {0, 12, 1}, // TGParameterPitchBenderStep + {0, 12, 1}, // TGParameterPitchBendRange + {0, 12, 1}, // TGParameterPitchBendStep {0, 1, 1, ToPortaMode}, // TGParameterPortamentoMode {0, 1, 1, ToPortaGlissando}, // TGParameterPortamentoGlissando {0, 99, 1} // TGParameterPortamentoTime From 374bd68664cc70f519377981c2290b2b15804225 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:17:37 -0300 Subject: [PATCH 31/37] Update uimenu.h --- src/uimenu.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/uimenu.h b/src/uimenu.h index 2a78b46..b130e4c 100644 --- a/src/uimenu.h +++ b/src/uimenu.h @@ -135,7 +135,7 @@ private: static const TMenuItem s_EditVoiceMenu[]; static const TMenuItem s_OperatorMenu[]; static const TMenuItem s_SaveMenu[]; - static const TMenuItem s_EditPitchBenderMenu[]; + static const TMenuItem s_EditPitchBendMenu[]; static const TMenuItem s_EditPortamentoMenu[]; static const TParameter s_GlobalParameter[]; From a1cc3e501e0a6a10b4ead6ddeae753897a180722 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sat, 14 May 2022 15:26:39 -0300 Subject: [PATCH 32/37] Update minidexed.cpp --- src/minidexed.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index dc61660..c4f4b40 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -192,11 +192,11 @@ bool CMiniDexed::Initialize (void) SetMasterTune (m_PerformanceConfig.GetDetune (nTG), nTG); SetCutoff (m_PerformanceConfig.GetCutoff (nTG), nTG); SetResonance (m_PerformanceConfig.GetResonance (nTG), nTG); - SetPitchbendRange (m_PerformanceConfig.GetPitchBendRange (nTG), nTG); - SetPitchbendStep (m_PerformanceConfig.GetPitchBendStep (nTG), nTG); - SetPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); - SetPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); - SetPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); + setPitchbendRange (m_PerformanceConfig.GetPitchBendRange (nTG), nTG); + setPitchbendStep (m_PerformanceConfig.GetPitchBendStep (nTG), nTG); + setPortamentoMode (m_PerformanceConfig.GetPortamentoMode (nTG), nTG); + setPortamentoGlissando (m_PerformanceConfig.GetPortamentoGlissando (nTG), nTG); + setPortamentoTime (m_PerformanceConfig.GetPortamentoTime (nTG), nTG); m_nNoteLimitLow[nTG] = m_PerformanceConfig.GetNoteLimitLow (nTG); m_nNoteLimitHigh[nTG] = m_PerformanceConfig.GetNoteLimitHigh (nTG); @@ -664,11 +664,11 @@ void CMiniDexed::SetTGParameter (TTGParameter Parameter, int nValue, unsigned nT case TGParameterMasterTune: SetMasterTune (nValue, nTG); break; case TGParameterCutoff: SetCutoff (nValue, nTG); break; case TGParameterResonance: SetResonance (nValue, nTG); break; - case TGParameterPitchBendRange: SetPitchbendRange (nValue, nTG); break; - case TGParameterPitchBendStep: SetPitchbendStep (nValue, nTG); break; - case TGParameterPortamentoMode: SetPortamentoMode (nValue, nTG); break; - case TGParameterPortamentoGlissando: SetPortamentoGlissando (nValue, nTG); break; - case TGParameterPortamentoTime: SetPortamentoTime (nValue, nTG); break; + case TGParameterPitchBendRange: setPitchbendRange (nValue, nTG); break; + case TGParameterPitchBendStep: setPitchbendStep (nValue, nTG); break; + case TGParameterPortamentoMode: setPortamentoMode (nValue, nTG); break; + case TGParameterPortamentoGlissando: setPortamentoGlissando (nValue, nTG); break; + case TGParameterPortamentoTime: setPortamentoTime (nValue, nTG); break; case TGParameterMIDIChannel: assert (0 <= nValue && nValue <= 255); From 93014b40f7521bba73fe7a0dd171dc3dc23c4401 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sun, 15 May 2022 20:43:07 -0300 Subject: [PATCH 33/37] Update performanceconfig.cpp --- src/performanceconfig.cpp | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/src/performanceconfig.cpp b/src/performanceconfig.cpp index 5c381ec..88ffb37 100644 --- a/src/performanceconfig.cpp +++ b/src/performanceconfig.cpp @@ -113,6 +113,9 @@ bool CPerformanceConfig::Load (void) PropertyName.Format ("PortamentoTime%u", nTG+1); m_nPortamentoTime[nTG] = m_Properties.GetNumber (PropertyName, 0); + + PropertyName.Format ("VoiceData%u", nTG+1); + m_nVoiceDataTxt[nTG] = m_Properties.GetString (PropertyName, 0); } m_bCompressorEnable = m_Properties.GetNumber ("CompressorEnable", 1) != 0; @@ -199,6 +202,10 @@ bool CPerformanceConfig::Save (void) PropertyName.Format ("PortamentoTime%u", nTG+1); m_Properties.SetNumber (PropertyName, m_nPortamentoTime[nTG]); + + PropertyName.Format ("VoiceData%u", nTG+1); + char *cstr = &m_nVoiceDataTxt[nTG][0]; + m_Properties.SetString (PropertyName, cstr); } m_Properties.SetNumber ("CompressorEnable", m_bCompressorEnable ? 1 : 0); @@ -501,3 +508,33 @@ unsigned CPerformanceConfig::GetPortamentoTime (unsigned nTG) const assert (nTG < CConfig::ToneGenerators); return m_nPortamentoTime[nTG]; } + +void CPerformanceConfig::SetVoiceDataToTxt (const uint8_t *pData, unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + m_nVoiceDataTxt[nTG] = ""; + char nDtoH[]="0123456789ABCDEF"; + for (int i = 0; i < NUM_VOICE_PARAM; i++) + { + m_nVoiceDataTxt[nTG] += nDtoH[(pData[i] & 0xF0)/16]; + m_nVoiceDataTxt[nTG] += nDtoH[pData[i] & 0x0F] ; + if ( i < (NUM_VOICE_PARAM-1) ) + { + m_nVoiceDataTxt[nTG] += " "; + } + } +} + +uint8_t *CPerformanceConfig::GetVoiceDataFromTxt (unsigned nTG) +{ + assert (nTG < CConfig::ToneGenerators); + static uint8_t pData[NUM_VOICE_PARAM]; + std::string nHtoD="0123456789ABCDEF"; + + for (int i=0; i Date: Sun, 15 May 2022 20:58:40 -0300 Subject: [PATCH 34/37] Update performanceconfig.h --- src/performanceconfig.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/performanceconfig.h b/src/performanceconfig.h index bf7617a..bd73aa9 100644 --- a/src/performanceconfig.h +++ b/src/performanceconfig.h @@ -26,6 +26,7 @@ #include "config.h" #include #include +#define NUM_VOICE_PARAM 156 class CPerformanceConfig // Performance configuration { @@ -55,6 +56,8 @@ public: unsigned GetPortamentoMode (unsigned nTG) const; // 0 .. 1 unsigned GetPortamentoGlissando (unsigned nTG) const; // 0 .. 1 unsigned GetPortamentoTime (unsigned nTG) const; // 0 .. 99 + void SetVoiceDataToTxt (const uint8_t *pData, unsigned nTG); + uint8_t *GetVoiceDataFromTxt (unsigned nTG); void SetBankNumber (unsigned nValue, unsigned nTG); void SetVoiceNumber (unsigned nValue, unsigned nTG); @@ -113,6 +116,7 @@ private: unsigned m_nPortamentoMode[CConfig::ToneGenerators]; unsigned m_nPortamentoGlissando[CConfig::ToneGenerators]; unsigned m_nPortamentoTime[CConfig::ToneGenerators]; + std::string m_nVoiceDataTxt[CConfig::ToneGenerators]; bool m_bCompressorEnable; bool m_bReverbEnable; From 0f197cd3618d564909cda10b0b98e5d6b458c2d5 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sun, 15 May 2022 21:02:11 -0300 Subject: [PATCH 35/37] Update minidexed.cpp --- src/minidexed.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/minidexed.cpp b/src/minidexed.cpp index 21e79f1..8a3376f 100644 --- a/src/minidexed.cpp +++ b/src/minidexed.cpp @@ -201,7 +201,9 @@ bool CMiniDexed::Initialize (void) m_nNoteLimitLow[nTG] = m_PerformanceConfig.GetNoteLimitLow (nTG); m_nNoteLimitHigh[nTG] = m_PerformanceConfig.GetNoteLimitHigh (nTG); m_nNoteShift[nTG] = m_PerformanceConfig.GetNoteShift (nTG); - + uint8_t* tVoiceData = m_PerformanceConfig.GetVoiceDataFromTxt(nTG); + m_pTG[nTG]->loadVoiceParameters(tVoiceData); + SetReverbSend (m_PerformanceConfig.GetReverbSend (nTG), nTG); } @@ -955,6 +957,8 @@ bool CMiniDexed::SavePerformance (void) m_PerformanceConfig.SetNoteShift (m_nNoteShift[nTG], nTG); m_PerformanceConfig.SetReverbSend (m_nReverbSend[nTG], nTG); + m_pTG[nTG]->getVoiceData(m_nRawVoiceData); + m_PerformanceConfig.SetVoiceDataToTxt (m_nRawVoiceData, nTG); } m_PerformanceConfig.SetCompressorEnable (!!m_nParameter[ParameterCompressorEnable]); From 1a8568072017fb79e9cd002f8e7949e658b8ea84 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sun, 15 May 2022 21:07:33 -0300 Subject: [PATCH 36/37] Update minidexed.h --- src/minidexed.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/minidexed.h b/src/minidexed.h index 66beb35..93ff9df 100644 --- a/src/minidexed.h +++ b/src/minidexed.h @@ -193,6 +193,8 @@ private: int m_nNoteShift[CConfig::ToneGenerators]; unsigned m_nReverbSend[CConfig::ToneGenerators]; + + uint8_t m_nRawVoiceData[156]; CUserInterface m_UI; CSysExFileLoader m_SysExFileLoader; From db9747cf8aca097752c5ed4c4afa4a7366e2ba26 Mon Sep 17 00:00:00 2001 From: arsamus Date: Sun, 15 May 2022 23:38:13 -0300 Subject: [PATCH 37/37] Update performance.ini --- src/performance.ini | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/performance.ini b/src/performance.ini index bdd3d66..d1abdcc 100644 --- a/src/performance.ini +++ b/src/performance.ini @@ -20,6 +20,7 @@ #PortamentoMode#=0 # 0 .. 1 #PortamentoGlissando#=0 # 0 .. 1 #PortamentoTime#=0 # 0 .. 99 +#VoiceData#= # space separated hex numbers of 156 voice parameters. Example: 5F 1D 14 32 63 [....] 20 55 # TG1 BankNumber1=0 @@ -39,6 +40,7 @@ PitchBendStep1=0 PortamentoMode1=0 PortamentoGlissando1=0 PortamentoTime1=0 +VoiceData1=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG2 BankNumber2=0 @@ -58,6 +60,7 @@ PitchBendStep2=0 PortamentoMode2=0 PortamentoGlissando2=0 PortamentoTime2=0 +VoiceData2=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG3 BankNumber3=0 @@ -77,6 +80,7 @@ PitchBendStep3=0 PortamentoMode3=0 PortamentoGlissando3=0 PortamentoTime3=0 +VoiceData3=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG4 BankNumber4=0 @@ -96,6 +100,7 @@ PitchBendStep4=0 PortamentoMode4=0 PortamentoGlissando4=0 PortamentoTime4=0 +VoiceData4=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG5 BankNumber5=0 @@ -115,6 +120,7 @@ PitchBendStep5=0 PortamentoMode5=0 PortamentoGlissando5=0 PortamentoTime5=0 +VoiceData5=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG6 BankNumber6=0 @@ -134,6 +140,7 @@ PitchBendStep6=0 PortamentoMode6=0 PortamentoGlissando6=0 PortamentoTime6=0 +VoiceData6=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG7 BankNumber7=0 @@ -153,6 +160,7 @@ PitchBendStep7=0 PortamentoMode7=0 PortamentoGlissando7=0 PortamentoTime7=0 +VoiceData7=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # TG8 BankNumber8=0 @@ -172,6 +180,7 @@ PitchBendStep8=0 PortamentoMode8=0 PortamentoGlissando8=0 PortamentoTime8=0 +VoiceData8=5F 1D 14 32 63 5F 00 00 29 00 13 00 00 03 00 06 4F 00 01 00 0E 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 00 63 00 01 00 00 5F 1D 14 32 63 5F 00 00 00 00 00 00 00 03 00 06 59 00 01 00 07 5F 14 14 32 63 5F 00 00 00 00 00 00 00 03 00 02 63 00 01 00 07 5F 32 23 4E 63 4B 00 00 00 00 00 00 00 03 00 07 3A 00 0E 00 07 60 19 19 43 63 4B 00 00 00 00 00 00 00 03 00 02 63 00 01 00 0A 5E 43 5F 3C 32 32 32 32 03 06 00 0F 21 00 00 00 04 02 18 45 2E 50 49 41 4E 4F 20 31 20 55 # Effects #CompressorEnable=1 # 0: off, 1: on