gearmulator

Emulation of classic VA synths of the late 90s/2000s that are based on Motorola 56300 family DSPs
Log | Files | Refs | Submodules | README | LICENSE

commit 095fbf2b64ce1f7de800cc0d8c7d3c903e9b3537
parent 899cc9836ac454e7409f06dcccb8d4afad3a8441
Author: dsp56300 <dsp56300@users.noreply.github.com>
Date:   Tue, 23 Apr 2024 19:39:45 +0200

add support for Rack Classic and Rack XL via midi OS update

Diffstat:
Msource/virusLib/device.cpp | 20+++++++++++++++-----
Msource/virusLib/midiFileToRomData.cpp | 2++
2 files changed, 17 insertions(+), 5 deletions(-)

diff --git a/source/virusLib/device.cpp b/source/virusLib/device.cpp @@ -39,15 +39,25 @@ namespace virusLib // m_dsp->getMemory().saveAssembly("P.asm", 0, m_dsp->getMemory().sizeP(), true, false, m_dsp->getDSP().getPeriph(0), m_dsp->getDSP().getPeriph(1)); - if(m_rom.getModel() == DeviceModel::A) + switch(m_rom.getModel()) { + case DeviceModel::A: // The A does not send any event to notify that it has finished booting dummyProcess(32); - m_dsp->disableESSI1(); - } - else - { + break; + case DeviceModel::B: + // Rack Classic doesn't send that it has finished booting either, wait a bit for the event but abort if it takes too long + { + constexpr auto maxRetries = 256; + uint32_t r=0; + while(!m_mc->dspHasBooted() && ++r <= maxRetries) + dummyProcess(8); + if(r >= maxRetries) + LOG("Timed out while waiting for the device to finish booting, expecting that it has booted"); + } + break; + default: while(!m_mc->dspHasBooted()) dummyProcess(8); } diff --git a/source/virusLib/midiFileToRomData.cpp b/source/virusLib/midiFileToRomData.cpp @@ -52,8 +52,10 @@ namespace virusLib { case 0x50: // Virus A case 0x53: // Virus B OS + case 0x54: // Virus Rack Classic (B) case 0x55: // Virus B Demo case 0x57: // Virus C + case 0x58: // Virus Rack XL (C) { const auto msb = _packet[6]; // packet number MSB const auto lsb = _packet[7]; // packet number LSB