Using 2 MFTs - Need to send data to one of them
Results 1 to 6 of 6
  1. #1
    Tech Convert
    Join Date
    Oct 2015
    Posts
    10

    Default Using 2 MFTs - Need to send data to one of them

    Ok, I've got two of these sweet knob machines. My primary DAW for mixing is Reaper, which isn't too hot on feedback , but good on midi learning.

    MFT #1 is set to channel 1 and CC00-63, MFT #2 is set to channel 1 and CC64-126. So far so good.

    But I want to send a message to one of them(not both though maybe that would work) to change banks, because the buttons on the side are much harder to press when the units are close together. In other words I want to remote control bank-switching.

    In fact, I'd like to do this on the unit itself without using the side buttons, but you can't. So I'm putting together a script for OSCII-bot (by Cockos, the folks who made Reaper) that'll present an OSC control surface to Reaper but receive and send out midi data from my Novation Dicer and to the MFT units to control the bank switching.

    OSCII-bot sets up a target MIDI device by matching a partial string with the device name. And thus, because both MFT units have the same name, this isn't going to work.

    So how can I change the device name of one of my MFT units ?
    Open-source firmware ? I'd hex-edit a firmware image, but how do I get that ? The MF utility can only address one MFT unit at a time, which isn't a problem, but it doesn't have a "dump firmware" function.

    Can anyone help changing the device name of an MFT unit ?

  2. #2
    Tech Guru Patch's Avatar
    Join Date
    Dec 2008
    Location
    Bristol, UK
    Posts
    6,481

    Default

    If you're on a PC, you can use Midi-Ox/Midi-Yoke to do this...
    DJ'ing: 2x1200MK2, DJM 850, Dicers, F1, Zomo MC-1000, Sony MDR-v700, i7 Win 10 HP Envy
    Production: Ableton Live 8 and a mouse, Sennheiser HD400, Sony VAIO

    Click HERE to D/L Free Tracks from Soundcloud!!!
    https://www.facebook.com/Patchdj

  3. #3
    DJTT Mapping Ninja Moderator Stewe's Avatar
    Join Date
    Aug 2010
    Location
    MIDI
    Posts
    7,493

    Default

    Quote Originally Posted by AironAudio View Post
    In fact, I'd like to do this on the unit itself without using the side buttons, but you can't.
    You can select different banks via encoders if you send following CC values:

    Bank 1 = Ch.04.CC.000
    Bank 2 = Ch.04.CC.001
    Bank 3 = Ch.04.CC.002
    Bank 4 = Ch.04.CC.003

    Hope this helps.
    Cheers,

  4. #4
    DJTT Administrator del Ritmo padi_04's Avatar
    Join Date
    Nov 2009
    Location
    Argentina
    Posts
    6,553

    Default

    ^just remember to change those per bank if you want to let's say assign the top row to handle bank navigation like the Classics had.

  5. #5
    DJTT Mapping Ninja Moderator Stewe's Avatar
    Join Date
    Aug 2010
    Location
    MIDI
    Posts
    7,493

    Default

    ^Exactly!

  6. #6
    Tech Convert
    Join Date
    Oct 2015
    Posts
    10

    Default

    Got it done. Thank you.

    The folks at Cockos were nice enough to add an API function that I can use to send a midi message directly to a midi device that Reaper knows about. It's available in the latest v5.33pre1 and up in Reapers pre-release forum section.

    Thus, I wrote a Lua script(you can write stuff in EEL, Lua, Python or C++) that scans the list of available devices, picks up the ones I want and sends them the message. I had to create one script per bank-choice command. Those could then be fired off by any trigger in Reaper, such as keyboard shortcuts, midi notes, midi CC messages, OSC messages or even other scripts.

    Right now I have some buttons on an X-Touch Mini changing banks, though I might go for the encoder presses. Changing those assignments is easy.

    Here's the script, which I'm posting in the forum in a moment in this thread on the JS/Scripting section of Reaper forum. It's also downloadable here: http://stash.reaper.fm/29565/mft_bankcontrol_1.lua

    As you can see, my two Twisters are named "Twister1" and "Twister2". This is what Reaper calls them, and I changed that in the Preferences / Midi Devices / Midi Output device list. Just right-click on the entry and change it there. If you want to do this too, don't forget to enable output to the device as well.

    Now I need to figure out how to get feedback out to the Twisters. That's gonna be a handful.

    Code:
    -- Send midi note message to target device(s)
    -- requires Reaper 5.33pre1 or higher
    
    -- Target Configuration --
    local midichan = 4
    local mftbank = 1 -- Midifighter Twister Bank
    local vel = 127
    local target_devices = { "Twister1" , "Twister2" }
    --Target Configuration end --
    
    msg_flag = false;
    function msg(val) ; if msg_flag then ; reaper.ShowConsoleMsg(tostring(val).."\n");end;end
    function msgclr() ; if msg_flag then ; reaper.ShowConsoleMsg("");end;end
    local i,k = 0 , 0
    local target_devnum = {} -- array to collect device numbers
    
    local mdev_outno = reaper.GetNumMIDIOutputs() -- grab number of midi outputs in Reaper
    msgclr()
    msg("Midi Outs Reaper: " .. mdev_outno)
    msg("Stepping through devices...")
    
    for k=1, #target_devices, 1 do
      for i=1, mdev_outno, 1 do
        retval, mdev_name = reaper.GetMIDIOutputName(i, "")
        if retval then
          if string.find(mdev_name,target_devices[k]) then -- check for target device name(s)
            target_devnum[k] = i -- add device number to list
            msg("Device found. No." .. i .. " " .. mdev_name .." matches " .. target_devices[k])
          end
        end
      end
    end
    for i=1, #target_devnum, 1 do
      reaper.StuffMIDIMessage( target_devnum[i]+16,
                               '0x9'..string.format("%x", midichan-1), -- NoteOn
                                mftbank-1, -- MIDI note (bank-1 for MidiFighterTwister)
                                vel)  -- MIDI velocity
                                -- later we'll add a command execution list
      retval, mdev_name = reaper.GetMIDIOutputName(target_devnum[i], "")
      msg("Sent note to " .. mdev_name)
    end
    Last edited by AironAudio; 01-19-2017 at 03:51 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •