June 24, 2024, 02:14:57 am
Welcome, Guest. Please login or register
News:

Arturia Forums



Author Topic: *.mbpz reverse-engineered  (Read 8859 times)

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
*.mbpz reverse-engineered
« on: May 31, 2020, 09:39:20 pm »
Hello,

after a few days of programming I now have a program for analyzing a preset.
The program can be downloaded here: www.astro-electronic.de/MatrixBrute.exe

If you don't want to download a *.exe file, you can compile the C# code yourself, here is the whole C# project:
www.astro-electronic.de/source/MatrixBrute.zip

It works as follows:
1. Copy MatrixBrute.exe in a new and empty folder.
2. With Midi Control Center, create a file which contains _one_ preset. Only one. The filename must be test.mbpz 
3. Save this file in the same folder as above and start MatrixBrute.exe
4. The program will rename the input file to test.zip and extract two files. The first one is 0_nameOfThePreset and the other is 1_sequence . Only the first one will be analyzed. Warning: The program will delete all files beginning with "0_" and "1_" before it extracts the files. That's why you should run this program only in a new (and almost empty) folder!
5. In the left half of the window you see a comparison of the input file against the "Init" preset, along with many comments. This is automatically saved as "diff.txt" in the same folder.
6. In the right half you see a nice printout of all prameters of the preset. This is automatically saved as "printout.txt" in the same folder.

Below is a sample printout. Maybe someone else wants to reverse-engineer the sequence file? Reverse-Engineering wasn't difficult once I had figured out the tricky 7-bit to 8-bit conversion.

Michael
 
Code: [Select]
************* MatrixBrute Analyzer V1.0 by Michael Koch 2020 ************** Page 1 *****

Name of this preset: Mysterious

VCO1:                          VCO2:                          VCO3-LFO3:
Fine               0%          Fine               0%         
Coarse           -50%          Coarse            12%          Coarse            75%
Sin/Squ            0%          Sin/Squ            0%          Wave       Triangular
Sub Level         67%          Sub Level          0%          LFO Div            16
Ultrasaw           0%          Ultrasaw           0%          Kbd Track          On
Saw Level         49%          Saw Level         70%
Pulse Width        0%          Pulse Width        0%
Square Level       0%          Square Level       0%          NOISE:
Metalizer        100%          Metalizer        100%          Type            White
Tri Level        100%          Tri Level        100%

AUDIO MOD:                     VCO SYNC:                      WHEELS:
VCO1>VCO2          0%          VCO2>VCO1         Off          Mod Wheel      Matrix
VCO1<VCO3>VCO2     0%                                         Bend Range         8%
VCF1<VCO3>VCF2     0%          VOICE:
VCO1<Noise>VCF1    0%          Mode       Monophonic

KEYBOARD:                      GLIDE:                         PLAY CONTROL:
Octave              0          Glide             57%          Key Hold          Off
                               Glide On/Off       On          Note Priority    Last
                                                              Legato          Glide
MIXER:
VCO1 Level       100%          Filter           Both
VCO2 Level       100%          Filter        Steiner
VCO3 Level        88%          Filter        Steiner
Noise Level        0%          Filter           None
Ext. Level         0%          Filter           None

LFO1:                          LFO2:
Phase              0%          Delay              0%
Seg-Sync          Off          Seg-Sync          Off
Rate              33%          Rate              34%
Wave            Sinus          Wave            Sinus
Retrig            Off          Retrig            Off

VCF1 STEINER:                  VCF2 LADDER:                   FILTER ROUTING:
Mode               LP          Mode               LP          Parallel
Slope            24dB          Slope            24dB
Drive              0%          Drive              0%
Brute Factor       0%          Brute Factor       0%
Cutoff            59%          Cutoff            88%
Env Amt          -41%          Env Amt          -50%
Resonance         36%          Resonance         63%
Steiner Out       93%          Ladder Out       100%

ENV1 (VCF):                    ENV2 (VCA):                    ENV3:
Velo / VCF         0%          Velo / VCF         0%          Delay              0%
Attack            72%          Attack            45%          Attack            72%
Decay             83%          Decay              0%          Decay             82%
Sustain            0%          Sustain          100%          Sustain            0%
Release           53%          Release           69%          Release           42%

ANALOG EFFECTS:
Delay Time       100%          Sync              Off
Regeneration      80%          Mode     Stereo Delay
Tone/Rate         46%
Width/Depth      100%
Dry/Wet           52%


************* MatrixBrute Analyzer V1.0 by Michael Koch 2020 ************** Page 2 *****

   1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
A  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  A
B  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  B
C  -  -  -  -  -  -  -  -  -  -  -  -  -  -  M  M  -  -  -  -  -  -  -  -  -  -  -  -  C
D  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  D
E  M  -  -  -  M  -  -  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  E
F  -  -  -  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  F
G  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  G
H  -  -  -  -  -  -  -  -  -  -  M  -  M  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  H
I  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  I
J  M  -  -  -  M  -  -  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  J
K  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  K
L  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  L
M  -  -  -  -  -  -  -  -  M  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  M
N  -  -  -  -  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  N
O  -  -  -  -  -  -  -  -  -  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  O
P  -  -  -  M  -  -  -  M  -  -  -  -  -  -  M  -  -  -  -  -  -  -  -  -  -  -  -  -  P
   1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28

Column 1 has destination [VCO1 Pitch] and depends on:
             6% Row E [LFO1]
             2% Row J [Aftertouch]

Column 4 has destination [VCO1 Metal] and depends on:
           -75% Row P [Exp2/M4]

Column 5 has destination [VCO2 Pitch] and depends on:
             6% Row E [LFO1]
             2% Row J [Aftertouch]

Column 8 has destination [VCO2 Metal] and depends on:
           -61% Row P [Exp2/M4]

Column 9 has destination [Steiner Cutoff] and depends on:
            60% Row M [M1]

Column 10 has destination [Ladder Cutoff] and depends on:
             0% Row F [LFO2]
            60% Row M [M1]

Column 11 has destination [LFO1 AMT] and depends on:
           -34% Row H [Mod Wheel]
          -100% Row N [M2]

Column 13 has destination [LFO1 Rate] and depends on:
            54% Row H [Mod Wheel]

Column 14 has destination [VCO3 Coarse] and depends on:
            16% Row E [LFO1]
            19% Row H [Mod Wheel]
             6% Row J [Aftertouch]

Column 15 has destination [ModAmount F10] and depends on:
            38% Row C [ENV3]
           100% Row P [Exp2/M4]

Column 16 has destination [LFO2 Rate] and depends on:
            60% Row C [ENV3]
            49% Row O [Exp1/M3]


« Last Edit: October 14, 2022, 08:54:01 pm by mkoch »

Processaurus

  • Newbie
  • Jr. Member
  • *
  • Posts: 84
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #1 on: May 31, 2020, 10:46:51 pm »
Wow! Thanks for sharing that!

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #2 on: May 31, 2020, 11:12:37 pm »
Known bug: It crashes if the name of the preset contains space characters.
Workaround: Use the Midi Control Center to change the name, just replace the spaces by underlines.

Michael

Lunatic Sound

  • Full Member
  • ***
  • Posts: 142
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #3 on: June 01, 2020, 12:13:22 am »
Wow. Are these rounded values? Or is everything stored as integers?

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #4 on: June 01, 2020, 07:25:31 am »
Wow. Are these rounded values? Or is everything stored as integers?

Everything is stored as 16-bit integers. The percent values in my printout file are rounded.

Michael

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #5 on: June 01, 2020, 08:59:20 am »
In Midi Control Center most presets are shown blue, but some are orange-brown. What's the meaning of the different colors? I can't find it in the manual.
"S" means there is a sequence, right?

Michael

STM

  • Apprentice
  • *
  • Posts: 49
  • Karma: 1
Re: *.mbpz reverse-engineered
« Reply #6 on: June 01, 2020, 11:18:40 am »
Great! Thanks for your efforts!

DrJustice

  • Super Doc
  • Administrator
  • Hero Member
  • *****
  • Posts: 1.046
  • Karma: 480
Re: *.mbpz reverse-engineered
« Reply #7 on: June 01, 2020, 04:59:39 pm »
Good job, Michael! :)

As we know the MCC can transfer single patches over USB MIDI - I'd think those patches will be in the same format, including the 7 + 1 bit packing. The MIDI monitor shows the sysex traffic.

And yes, an "S" mean there's a sequence, and if it's orange that means the Sequencer button is On. However I'm not sure about what the criteria for "No sequence" (no "S") are. Some of the "S" patches have no sequence (i.e. no sequencer buttons lit). Could be that only a fresh Init patch or a patch where the sequencer has been reset (Panel + SEQ) is reported as "no sequence"(?)

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #8 on: June 01, 2020, 07:16:51 pm »
Some more explanations about the file format. The *.mbpz file is a *.zip file with wrong extension. It contains two files, 0_NameOfThePreset and 1_sequence. The beginning of the 0_Init file looks like this:

Code: [Select]
22 serialization::archive 10 0 4 4 1538 4 Init 5 0 0 18 000000100100100000 0 0 32 1600 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...
22 is the length of the following string "serialization::archive"
10 might be the length of the following string "0 4 4 1538" but I don't know the meaning of these numbers
4 is the length of the string "Init", this is of course the name of the preset
5 0 0 18 000000100100100000 0 0 32   I don't know what this is, and it changes sometimes
1600 is the number of the following 7-bit values.
These 1600 7-bit values must be converted to 1400 Bytes. Look in the source code how the conversion is done. The meaning of the 1400 bytes is described in helpText[] in the source code. There are a few bytes that are still unknown.

Michael

Lunatic Sound

  • Full Member
  • ***
  • Posts: 142
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #9 on: June 03, 2020, 12:30:09 am »
Thanks Michael!

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #10 on: June 03, 2020, 06:58:53 pm »
I have uploaded a new version, same links as above. Three small improvements:
1. The name of the preset may now contain space characters.
2. The "Coarse" values of the three VCO's are also shown in semitone steps.
3. The output format of the printout is now Rich Text Format.

If you find out the meaning of any of those bytes that are still marked as "unknown" in the diff.txt file, please let me know.

Michael

endreola

  • Full Member
  • ***
  • Posts: 156
  • Karma: 3
Re: *.mbpz reverse-engineered
« Reply #11 on: June 04, 2020, 06:07:23 am »
... Look in the source code how the conversion is done. The meaning of the 1400 bytes is described in helpText[] in the source code.

Is the actual source code posted online or are you just scraping readable text from FW image, (e.g. od -c)?

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #12 on: June 04, 2020, 08:50:36 am »
... Look in the source code how the conversion is done. The meaning of the 1400 bytes is described in helpText[] in the source code.

Is the actual source code posted online or are you just scraping readable text from FW image, (e.g. od -c)?

I don't understand your question. The posted source code was written by me.

Michael

endreola

  • Full Member
  • ***
  • Posts: 156
  • Karma: 3
Re: *.mbpz reverse-engineered
« Reply #13 on: June 09, 2020, 06:29:34 am »
Yea, I understand.  At first I thought you were making reference to MCC source.  And I'd be shocked, albeit pleasantly surprised, if Arturia actually released the code to the GP.

mkoch

  • Apprentice
  • *
  • Posts: 46
  • Karma: 2
Re: *.mbpz reverse-engineered
« Reply #14 on: June 13, 2020, 10:53:05 am »
When you analyze an unknown preset, it's also good to know which modules are used and which are not used. I'd like to add this info to my software. The question is how to decide if a module of the MatrixBrute is actually used. Please let me know if you agree to the following logic:


Thanks,
Michael
 

 

Carbonate design by Bloc
SMF 2.0.17 | SMF © 2019, Simple Machines