Send/receive patterns with SYSEX (documentation?)

So, when sending or receiving sysex, what’s the fastest way to do it? I’m wondering if it’s worth getting a TM 1 for this kind of thing, and for sending many ccs at once…and with the analog machines, does sending sysex (from m4l , not c6) over usb work at turbo speed ?

never compared the speeds, but I would think the built-in USB of the analog machines is either as fast or faster than the TM1. don’t think it’s worth getting one for AR/AF.

sending many CCs at once = bad bad bad, from experience. The AR doesn’t like it, especially in live-rec mode across multiple tracks :stuck_out_tongue_winking_eye:

it’s a lot better to send a kit sysex if you want to change many parameters at once, the machines handles these very well.

1 Like

Thanks for your reply. I had a look at how rytm responds to ccs today, Sending a whole kit of about 500 ccs doesn’t work properly unless I limit the speed of the ccs to one per millisecond. THen it seems pretty reliable. I can’t notice any difference in performance between the USB midi and DIN midi. They both work with 1ms choking.
I’d love to work out the Rytm kit /pattern sysex structure, but it looks difficult. Also, im sending groups of ccs mostly rather than all of them, so sending a sysex kit might be overkill.
Trig ccs are messed up now since 1.22 they seem to control the LFO!

1 Like

Has anyone ever managed to unpack a Monomachine kit dump successfully? I managed to unpack Rytm kit sysex dumps, but I cannot work out how to decode Monomachine Kit dumps. Can anyone help? The MnM Sysex pdf explains it as follows…

Conventions in this document
Bits are labeled from 0 and upwards. 7 bit data are referred to as data.
8 bit data are referred to as bytes.
How the checksums are calculated
The checksum is generated from the data marked in blue in the tables. It is the lower 14 bits of the sum of all the indicated data.
How the message length is calculated
The length at the end of the message is the number of bytes starting from version and ending with the checksum.
Packing Method
All dump packages on the Monomachine are packed. After that they are 7-bit encoded.
To unpack check if bit 7 is set. If it is the low 7 bits indicate that the next byte should be repeated this number of times in the resulting unpacked data structure.
If bit 7 is not set the byte should just be stored in the unpacked data structure. An 8-bit data, XX, repeated 1 time is encoded 0x81 XX.
A 7-bit data, YY, repeated 1 time is encoded YY.
How the 7 bit encoding is generated
As a SysEx message only allows 7 bit data, 8 bit data blocks are converted as follows:
The first data contains the MSB of the following, up to, 7 data, data[0…6]. Bit 6 is the MSB bit of data[0] and bit 0 is the MSB of data[6]. 7 bytes encodes to 8 data. 8 bytes encodes to 10 data.

The problem I’m getting is that when I convert the 7 bit data blocks back to 8 bit data (using the same method I successfully decoded Rytm’s kit dumps) I end up with alot of data that have high values (between 128 and 255). So when I then unpack using the method described here -

To unpack check if bit 7 is set. If it is the low 7 bits indicate that the next byte should be repeated this number of times in the resulting unpacked data structure.

I get large numbers of repeated bytes, which makes the unpacked structure several thousand bytes long , rather than the 700 or so of the unpacked structure that I’m aiming for. I can’t see what I’m doing wrong - any ideas?

I end up with alot of data that have high values

Those are the (F#) functions I’m using to convert to/from byte/7bit data, those appear to work fine with machine drum and monomachine, albeit on my monomachine, most of the sysex dump requests don’t work, so for now I’m trying it out on the sound pack files where I’m extracting a kit.

let byteToData bytes =
    let encodeBytes bytes =
        let mutable prefixByte = 0uy
        for i in 0 .. (Array.length bytes) - 1 do
            prefixByte <- prefixByte ||| ((bytes.[i] >>> 7) <<< (6 - i))
            bytes.[i] <- bytes.[i] &&& 0b01111111uy
        Array.concat [|Array.singleton prefixByte;bytes|]
   
    bytes
    |> Array.chunkBySize 7
    |> Array.collect encodeBytes

let dataToByte data =
    let inline prefixMask b i =
        let mask = 1uy <<< (6 - i)
       
        if b &&& mask <> 0uy then 0b10000000uy else 0uy

    let decodeData (data: byte array) =
        let prefix = data.[0]
        Array.init (data.Length - 1) (fun i -> data.[i + 1] ||| prefixMask prefix i)
       
    data
    |> Array.chunkBySize 8
    |> Array.collect decodeData

I get correct checksum and length compared to the bits at the end of the messages.

Is anyone able to issue kit or pattern request or even assign machine messages?

I’ve tried and so far the monomachine only handles the dump global settings message, other messages come back without the SysEx EOF flag.

Those are simple messages if anyone could try:

// request kit 2
f0 00 20 3c 03 00 53 01 f7

// assign dpro-dens to track 3 with init synthesis page
f0 00 20 3c 03 00 5b 02 33 02 f7

Those bug are hindering efforts to make separate editor, it would also be useful to have ability to ask kit in edit buffer beside saved kits, but this is apparently not supported by current OS.

I worked out my problem was that I was unpacking the bytes from the wrong end, I have all the data correctly now.
I can request kit and pattern dumps without a problem. All the sysex commands in the documentation work for me. Its a real shame we cant send a kit or pattern dump to the MM without entering the sysex page on the machine though…

1 Like

First rmessage gives me back

0000  F0 00 20 3C 03 00 52 02  01 01 00 4D 41 43 48 49  |   <  R    MACHI|
0010  4E 45 00 00 45 4F 00 7E  70 6C 08 62 6D 75 07 00  |NE  EO ~pl bmu  |
0020  40 00 01 05 4E 2D 36 6A  40 02 12 00 7F 03 00 43  |@   N-6j@      C|
0030  04 40 20 00 02 40 1C 00  7F 00 42 02 58 27 76 7F  | @   @    B X'v |
0040  03 00 02 48 58 4A 52 6B  03 00 22 40 02 00 01 40  |   HXJRk  "@   @|
0050  02 00 0A 06 64 40 07 00  02 7F 42 04 00 54 77 7F  |    d@    B  Tw |
0060  04 00 00 40 0E 00 4D 25  48 72 04 40 00 0C 20 03  |   @  M%Hr @    |
0070  00 14 00 2B 6C 53 54 00  30 50 02 1C 00 7F 00 40  |   +lST 0P     @|
0080  02 00 01 01 40 00 04 3F  08 02 00 00 1B 23 00 10  |    @  ?     #  |
0090  23 68 40 02 00 2D 40 00  1D 06 15 64 40 07 00 02  |#h@  -@    d@   |
00A0  7F 04 00 00 63 00 60 3F  10 00 54 02 40 02 00 02  |    c `?  T @   |
00B0  40 3B 10 5A 40 02 00 15  00 01 10 00 20 02 40 0C  |@; Z@         @ |
00C0  5F 00 40 02 40 1C 00 7F  07 40 44 02 00 01 40 02  |_ @ @    @D   @ |
00D0  00 15 00 08 00 10 52 1C  00 18 00 31 18 25 4A 64  |      R    1 %Jd|
00E0  40 00 05 3F 06 64 40 07  00 02 24 7F 04 00 5A 02  |@  ? d@   $   Z |
00F0  00 60 40 03 00 40 0E 00  3C 1F 00 41 60 5D 1C 04  | `@  @  <  A`]  |
0100  16 00 00 22 00 23 2B 56  0F 36 00 00 40 63 1C 30  |   " #+V 6  @c 0|
0110  39 00 20 58 02 00 52 5E  00 04 10 31 08 02 00 52  |9  X  R^   1   R|
0120  48 00 08 07 00 40 02 00  01 40 42 02 00 06 64 40  |H    @   @B   d@|
0130  07 00 50 02 7F 04 00 3C  40 7F 00 69 5C 1C 7F 3F  |  P    <@  i\  ?|
0140  2A 07 00 27 00 3B 5E 40  1D 00 24 7F 03 00 20 04  |*  ' ;^@  $     |
0150  40 00 00 10 40 2B 00 7F  00 40 44 02 00 01 40 03  |@   @+   @D   @ |
0160  00 40 44 02 00 01 40 03  00 40 44 02 00 01 40 02  | @D   @  @D   @ |
0170  00 06 15 64 40 07 00 02  7F 04 00 00 5C 66 60 20  |   d@       \f` |
0180  03 40 00 5B 40 19 22 3F  2B 4A 00 6E 2C 00 18 61  | @ [@ "?+J n,  a|
0190  00 1F 20 00 03 40 4C 26  00 60 01 4F 11 00 2B 00  |     @L& ` O  + |
01A0  40 02 09 00 01 40 03 00  40 02 09 00 01 40 03 00  |@    @  @    @  |
01B0  40 02 08 00 01 40 02 00  06 64 2A 40 07 00 02 7F  |@    @   d*@    |
01C0  04 00 01 01 04 03 06 08  0B 06 02 01 08 00 01 3F  |               ?|
01D0  05 00 00 02 00 03 05 02  00 01 40 05 00 03 00 02  |          @     |
01E0  04 02 10 00 01 05 00 03  00 02 04 00 02 00 01 05  |                |
01F0  00 02 11 01 03 02 02 00  01 05 04 00 02 00 03 02  |                |
0200  02 00 21 01 05 00 04 03  01 02 00 02 00 01 00 01  |  !             |
0210  00 01 11 00 05 02 00 07  05 03 00 00 01 00 01 00  |                |
0220  01 00 08 05 00 05 03 00  01 00 00 01 00 01 00 05  |                |
0230  00 05 41 03 00 01 00 01  00 02 04 02 00 07 05 03  |  A             |
0240  00 01 04 00 01 00 05 02  00 01 20 05 03 00 01 00  |                |
0250  01 00 02 02 00 03 02 05  03 00 1B 3F 00 01 41 00  |           ?  A |
0260  01 40 3E 00 01 60 01 56  04 00 1B 3F 00 01 41 00  | @>  ` V   ?  A |
0270  01 41 34 00 01 40 14 04  00 3F 31 00 01 41 00 0D  | A4  @   ?1  A  |
0280  00 01 63 40 05 00 3F 00  01 41 12 00 0C 02 3F 15  |  c@  ?  A    ? |
0290  04 00 1B 3F 00 01 41 00  01 40 34 00 01 40 03 04  |   ?  A  @4  @  |
02A0  00 3F 34 00 01 41 00 03  3F 10 43 04 00 3F 1F 3F  | ?4  A  ? C  ? ?|
02B0  09 7F 00 02 01 3C 03 12  6F 05 32 F7              |     <  o 2 |

Second message gives no response and changes nothing

Cheers

Ian

1 Like

@icottee @Bin I’m curious what were/is your midi interface?

I’m now trying with a TM-1 (without enabling turbo midi) and Dump Kit message does indeed work, but not with my UM-880 nor UM-550.

RME ff400, or Motu Microlite both seem to work