Korg Prophecy sysex

Home Forums General Using Ctrlr Korg Prophecy sysex

Viewing 16 posts - 1 through 16 (of 16 total)
  • Author
    Posts
  • #6719
    jms
    Participant
      • Topics: 6
      • Replies: 24
      • Total: 30

      Hello

      I’m working on a panel for the Prophecy.

      I am a beginner with Ctrlr, I have stumbled across a couple of issues that have managed to sort with the help of this forum, but right now i can’t really seem to find a solution for my current problem.

      In the Prophecy there’s a KeyTracking parameter that has -99 and +99 as the lowest and highest values respectively. The corresponding sysex messages I get in the midi monitor from the prophecy for the respective messages are:

      F0 42 30 41 41 01 6A 00 1D 01 F7 [for -99]

      F0 42 30 41 41 01 6A 00 63 00 F7 [for +99]

      Given this I have created a uiSlider, set to SySex under “MIDI message type”, with the following sysex message

      F0 42 30 41 41 01 6A 00 LS MS F7

      Have set “Maximum value the modulator can have” to 199

      Have set “Minimum value the modulator can have” to 0

      Have set “Minimum value” to -99

      Have set “Maximum value” to +99
      .

      If i have the uiSlider at +99 and drag it down to 0 all seems fine, i see the values descending from +99 to 0 on both Ctrlr and the Prophecy, but once I try to drag it below 0, in Ctrlr everything works fines and i see the values descending to -99 but in the Prophecy nothing happens, it stays at 0 whatever minus value is set in the slider. If I get back to 0 and go above it, then the Prophecy starts recognising the values again.

      In the MIDI monitor I have noticed that if i turn the knob in the Prophecy from 0 to -99 I get the messages

      F0 42 30 41 41 01 6A 00 00 00 F7 [0]
      F0 42 30 41 41 01 6A 00 7E 01 F7 [-1]
      F0 42 30 41 41 01 6A 00 7D 01 F7 [-2]
      F0 42 30 41 41 01 6A 00 7C 01 F7 [-3]

      F0 42 30 41 41 01 6A 00 1D 01 F7 [-99]

      while in Ctrlr if i turn the uiSlider down from 0 to -99 i get

      F0 42 30 41 41 01 6A 00 00 00 F7 [0]
      F0 42 30 41 41 01 6A 00 7E FF F7 [-1]
      F0 42 30 41 41 01 6A 00 7D FF F7 [-2]
      F0 42 30 41 41 01 6A 00 7C FF F7 [-3]

      F0 42 30 41 41 01 6A 00 1D FF F7 [-99]

      .

      I have also tried to
      set “Maximum value the modulator can have” to +99
      and
      set “Minimum value the modulator can have” to -99
      and Ctrlr displays exactly the same values in the Monitor.

      /end of report

      Would anyone be so kind to drop me a line on whatever i may be doing wrong?

      Thanks in advance for any given attention.

      #6720
      atom
      Keymaster
        • Topics: 159
        • Replies: 2945
        • Total: 3104
        • ★★★★★

        You need to find out how Korg encodes negative values in SysEx messages, it’s not in the MIDI specs so every manufacturer/device does it differently, it’s usually some bit set or something is added/subtracted from the value so it always is positive. Find out how it’s done.

        There is no standard way to send/receive NEGATIVE values in MIDI.

        From what i can deduce just by looking at the HEX message for -99, it’s possiby a simple subtraction, for -99 you do: 127 – 99 = 29 [1D] and set the first bit of the MS part to 1 (indicating it’s a negative number), but i don’t know paste here some negative sysex numbers that you receive from the prophecy -99, -50, -30.

        For you -99 – 99 i think the forward expression should be:

        lt (modulatorValue, 0, 128 + (128 - abs(modulatorValue)), modulatorValue)
        

        for a slider that has min set to -99 and max to 99 this should work (i can’t be sure). You need to figure out the reverse expression yourself.

        #6721
        jms
        Participant
          • Topics: 6
          • Replies: 24
          • Total: 30

          It works perfect!!
          Thanks so much Atom.

          Would it be asking to much for you to explain the expression?

          It’s fantastic it’s working but it would be cool to understand precisely what’s going on.

          Thank you.

          #6722
          atom
          Keymaster
            • Topics: 159
            • Replies: 2945
            • Total: 3104
            • ★★★★★

            Sure (one day i’ll write a manual i promise)

            It’s all like calling functions with parameters the idea is function (param1, param2, param3) etc.

            so, two functions are used:
            lt(p1, p2, r1, r2) – less then, it takes 4 parameters, p1 and p2 are the compared values, r1 and r2 arw what the function returns depending on the comparison outcome, if p1 < p2 it returns r1, otherwise it returns r2 abs(p1) - return the absolute value of p1 so you get (i'll seperate parts of the expression with new lines)

            lt (modulatorValue, 0, // if modulator value is less then zero then
            128 + (128 – abs(modulatorValue)), // return 128 + (128 – absolute value of modulator)
            modulatorValue) // otherwise just return the modulatorValue (anything higher then 0)
            

            and that’s it, it’s like a calculator just a bit more complex

            #6723
            jms
            Participant
              • Topics: 6
              • Replies: 24
              • Total: 30

              Got it!

              Very glad for you help Atom, cheers 🙂

              #6971
              jms
              Participant
                • Topics: 6
                • Replies: 24
                • Total: 30

                A Prophecy panel is almost finished, it should be up for sharing soon 🙂

                #6993
                jms
                Participant
                  • Topics: 6
                  • Replies: 24
                  • Total: 30

                  Hello,

                  Hoping you could help me out again Atom.

                  2 questions

                  I have a uiGroup and inside it I have a uiTabs component with several tabs configured.
                  Outside the uiGroup I have a uiCombo that is sending sysex messages to the Prophecy.

                  I wanted to be able to change tabs with the uiCombo already in use.
                  So everytime the value changed in the uiCombo the respective tab in that other group would be displayed, see what i mean?

                  I have seen something similar has already been done, but I don’t seem to find any like the one I have described. I.e. in the Virus, what seem to be tabs change to what seems to be uiTogglebuttons. There’s loads of Lua involved in the Virus panel, but i haven’t started digging Lua just yet, to really understand what is going on.

                  My other question is, how can I receive a sysex dump from the Prophecy, so all the parameters in Ctrlr are automatically configured to match the original Prophecy configuration for each patch?

                  Thanks for your time

                  #6995
                  jms
                  Participant
                    • Topics: 6
                    • Replies: 24
                    • Total: 30

                    Found an example for changing tabs with the uiCombo, also from earlier posts, sysex dump seems to be an in development feature. Ignore previous post.

                    #7091
                    jms
                    Participant
                      • Topics: 6
                      • Replies: 24
                      • Total: 30

                      I’m finished, yay!
                      I should say, almost… Still need to nail a workaround for sysex dumps.
                      Not the greatest UI as well, but everything’s there 🙂

                      Attachments:
                      You must be logged in to view attached files.
                      #7093
                      atom
                      Keymaster
                        • Topics: 159
                        • Replies: 2945
                        • Total: 3104
                        • ★★★★★

                        That’s very … yellow 🙂

                        post it in the Panels section, here is how http://ctrlr.org/uploading-a-new-panel/

                        #7096
                        jms
                        Participant
                          • Topics: 6
                          • Replies: 24
                          • Total: 30

                          will do, just need to tide a few little things.

                          #7140
                          ed_f
                          Participant
                            • Topics: 3
                            • Replies: 17
                            • Total: 20

                            jms – Looks like nice project a lot there. I am looking through it now.

                            Just curious about something. When I started using Ctrlr I found that uiSliders didn’t seem to work. I was happy to use uiImageSliders instead to create the look I wanted. But, I am reminded of this when I open your panel.

                            If I change any of the list or dropdown menus I see the midi message I would expect, in both the built in midi window and and external one I am using. But from what I can tell, not a single uiSlider (knob) sends a signal. Don’t know what I could be missing. I am using the Mac 1315 build which looks to me to be the latest. I must assume you didn’t have this issue. Can you tell me which version and platform you are using?

                            Nice work on the panel it is impressive! Thanks!

                            #7149
                            jms
                            Participant
                              • Topics: 6
                              • Replies: 24
                              • Total: 30

                              Hi ed, thanks 🙂

                              Im 99% sure i got your problem right… any interaction with any uiSliders gives you 0 entries in the internal and external midi monitors?

                              That’s quite odd, if you can get feedback alright from the lists and dropdowns!

                              Everything is working fine here.
                              I’m using the mac 1315 build as well.

                              Sorry, I really can’t think of anything for helping you :/

                              #7150
                              ed_f
                              Participant
                                • Topics: 3
                                • Replies: 17
                                • Total: 20

                                Thanks for the quick response. Wow very strange we are using the same build.

                                Yes you are correct. uiSlider no ouput. But lists and dropdowns send a nice complete midi event.

                                I even notice that in Ctrlr when I look at the Modulator Panel (and also at the xml) that if I have a uiImageSlider selected there is a field for “Current modulator value” that mirrors the value of the slider as I turn it. When I select a uiSlider that field disappears.

                                I will download and install again, it seems to be on my end.

                                But again, congrats on a great panel. Looks like you put a lot of work into it.

                                #7151
                                jms
                                Participant
                                  • Topics: 6
                                  • Replies: 24
                                  • Total: 30

                                  You shouldn’t need installing Ctrlr again, just delete all files in your system associated with Ctrlr and you should be good to go.

                                  EasyFind is a good tool for this, just type Ctrlr and delete everything that isn’t your panels.
                                  http://www.devontechnologies.com/products/freeware.html

                                  #7154
                                  ed_f
                                  Participant
                                    • Topics: 3
                                    • Replies: 17
                                    • Total: 20

                                    Well I went for the install just to be “sure” didn’t help.
                                    Interestingly, I tried the same tests on the mac in my studio. Same results, I can quickly whip up a uiImageSlider and control things, but uiSlider … nothing.

                                    strange

                                  Viewing 16 posts - 1 through 16 (of 16 total)
                                  • The forum ‘Using Ctrlr’ is closed to new topics and replies.
                                  There is currently 0 users and 86 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