Sysex value referencing earlier value

Home Forums General General MIDI discussion Sysex value referencing earlier value

Tagged: 

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #68774
    memorysplice
    Participant
      • Topics: 14
      • Replies: 59
      • Total: 73

      I have 2 sysex parameters. Sysex value 1 changes the the first parameter while the second parameter references the values on the 1st sysex message and incorporates it into its sysex message. The question is how do I get parameter 1 to reference parameter 2?

      15:46:48.399	From MX-1 USB4	SysEx		Roland 22 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 09 44 F7
      15:46:48.783	From MX-1 USB4	SysEx		Roland 22 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0A 43 F7
      15:46:49.196	From MX-1 USB4	SysEx		Roland 22 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0B 42 F7
      15:46:50.541	From MX-1 USB4	SysEx		Roland 22 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0C 41 F7
      15:46:52.782	From MX-1 USB4	SysEx		Roland 26 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0C 00 00 00 07 3A F7
      15:46:53.088	From MX-1 USB4	SysEx		Roland 26 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0C 00 00 00 08 39 F7
      15:46:53.392	From MX-1 USB4	SysEx		Roland 26 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0C 00 00 00 09 38 F7
      15:46:53.840	From MX-1 USB4	SysEx		Roland 26 bytes	F0 41 10 00 00 00 0E 12 19 70 2E 7A 00 00 00 01 00 00 01 0C 00 00 00 0A 37 F7
      
      #68790
      goodweather
      Participant
        • Topics: 45
        • Replies: 550
        • Total: 595
        • ★★★

        Hi, could you be more precise on what you try to achieve? Read sysex? write sysex? Simulate with rotary buttons?
        If the latter then you can have one uiImageSlider modulator building the first message then use an OnValueChange method to adjust the potential values of the second uiImageSlider modulator.
        Then with a third uiImageButton modulator you build and send your sysex message.
        But I don’t know if this is what you want to achieve…

        #68798
        memorysplice
        Participant
          • Topics: 14
          • Replies: 59
          • Total: 73

          I am trying to get knob #2 to reference the value from knob #1. When I change the value on knob #2 it is referencing the sysex value on knob #1.

          The 1st 4 sysex values listed are from knob #1 while the next 4 values are from knob #2.

          #69081
          Puppeteer
          Participant
            • Topics: 16
            • Replies: 185
            • Total: 201
            • ★★

            I’m not sure what you are trying to achieve here.

            Maybe some background on what Knob1 and Knob2 are controlling (ie Knob 1 sets oscillator, knob 2 controls PWM of that oscillator) or something similar.

            If you are trying to incorporate a byte/s from the knob1 sysex message into knob2 sysex message, you’ll need to use LUA to store the byte/s from knob1 (onValueChange) and use LUA on knob2 to assemble the SYSEX message and send it.

            The Puppeteer
            http://godlike.com.au

            #69346
            memorysplice
            Participant
              • Topics: 14
              • Replies: 59
              • Total: 73

              Sysex spec for jdxi

              Ok knob 1 is the “WMT1 Wave Number L (Mono)”. The sysex message is expressed as this messages coming out of the synth when changing the paramater.

              
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 01" 18 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 02" 17 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 03" 16 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 04" 15 F7
              

              Relevant parts of the message are separated by ” “.

              This is the sysex list for “WMT1 Wave Number R”

              
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 01" "00 01 0C 05" 06 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 01" "00 01 0C 04" 07 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 01" "00 01 0C 03" 08 F7
              F0 41 10 00 00 00 0E 12 19 70 2E 23 "00 00 00 00" "00 01 0C 01" "00 01 0C 02" 09 F7
              

              Relevant parts of the message are separated by ” “.

              I am needing to make a knob in ctrlr that will change “WMT1 Wave Number L” and I also need to make a knob in ctrlr for “WMT1 Wave Number R” parameters.

              After that I will need help making script that will update when I request sysex dump.

              Here is a dump example from the drum part of the synth.

              
              
              00  F0 41 10 00 00 00 0E 12  19 70 2E 00 49 4E 49 54  | A       p. INIT|
              10  20 50 41 52 54 49 41 4C  00 00 78 3C 40 00 40 00  | PARTIAL  x<@ @ |
              20  40 01 7F 00 00 00 1E 03  02 01 01 00 01 01 00 00  |@               |
              30  00 00 00 00 01 0C 02 00  01 0C 01 03 00 00 00 00  |                |
              40  40 40 40 01 01 7F 01 7F  00 00 01 00 00 00 00 01  |@@@             |
              50  00 00 01 0B 00 00 00 00  01 00 00 00 00 40 40 40  |             @@@|
              60  01 01 7F 01 7F 00 00 01  00 00 00 00 01 00 00 0F  |                |
              70  0A 00 00 00 00 01 00 00  00 00 40 40 40 01 01 7F  |          @@@   |
              80  01 7F 00 00 00 00 00 00  00 01 00 00 00 00 00 00  |                |
              90  00 00 01 00 00 00 00 40  40 40 01 01 7F 01 7F 00  |       @@@      |
              A0  00 40 40 40 40 00 28 50  28 40 22 5E 40 40 01 7F  | @@@@ (P(@"^@@  |
              B0  01 40 00 40 40 01 40 40  40 00 0A 0A 40 00 7F 7F  | @ @@ @@@   @   |
              C0  7F 00 01 60 40 40 00 0A  0A 64 7F 7F 7F 00 40 33  |    @@   d    @3|
              D0  F7                                                | |
              
              

              Here are examples of what I am using to update my panel so far.

              
              
              	panel:getModulatorByName("DRUM_BD1_Partial_Receive_Hold"):setModulatorValue(programData:getByte(42), true, true, true)
              
              -- byte43 reserved
              
              	panel:getModulatorByName("DRUM_BD1_WMT_Velocity_Control"):setModulatorValue(programData:getByte(44), true, true, true)
              

              My 2nd question is how do I change this to update my panel for my 2 knobs “WMT1 Wave Number L (Mono)” and “WMT1 Wave Number R” paramaters

              I know that WMT1 Wave Switch is byte 45 from the dump
              while WMT1 Wave Group Type = byte 46
              WMT1 Wave Group ID = bytes 47 through bytes 50
              WMT1 Wave Number L (Mono) = bytes 51 through bytes 54
              WMT1 Wave Number R = bytes 55 through bytes 58

              How do I combine the 4 bytes for each parameters above to so they will update in ctrlr?

              • This reply was modified 7 years, 10 months ago by memorysplice.
              Attachments:
              You must be logged in to view attached files.
              #69363
              Puppeteer
              Participant
                • Topics: 16
                • Replies: 185
                • Total: 201
                • ★★

                I think you are definitely in LUA territory here.

                There are 2 ways I would look at doing this. If the Wave Number L and Wave Number R parameters are quite short lists (ie 4 parameters each), you could look at using if statements to read the value of the Wave Number L know and if it’s a certain value either unhide a knob that has the relevant sysex programmed to it for the particular Wave Number L value, or a better way, especially for long lists of values is:

                Use concatenate to combine 2 sysex strings. Ie Set Wave Number L and send it’s sysex string on ValueChange and set Wave Number R where it sends Wave Number L concatenated with the 4 additional bytes and concatenated with the string termination (F7) that Wave Number R reads, and use the SendMidiNow() command to send the sysex string.

                Regarding receiving the sysex dump and setting the modulator values on the panel, you’ll need to program LUA in the OnMidiReceive (I think that’s what it’s called) event on the panel, and call a module. In the module, you’ll need code that checks the dump, and reads the various bytes and does things with them.

                This is quite a tricky part and something I’m in the process of learning myself.

                I’d recommend getting the panel to correctly send everything first as step 1. Once that’s all working, start looking at the receiving MIDI end.

                The Puppeteer
                http://godlike.com.au

              Viewing 6 posts - 1 through 6 (of 6 total)
              • The forum ‘General MIDI discussion’ is closed to new topics and replies.
              There is currently 0 users and 71 guests online
              No users are currently active
              Forum Statistics
              Threads: 2,495, Posts: 17,374, Members: 77,605
              Most users ever online was 12 on January 22, 2019 3:47 pm
              Ctrlr