Cannot map some multibyte controller inputs

Bug #1155192 reported by Circuitfry
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mixxx
Invalid
Low
Unassigned

Bug Description

Workin' on mapping the RMX 2. It seems to have some weird input for certain buttons, and other buttons are not being affected.

Mapping:
        <control><!-- LC1 Clear -->
         <status>0xB0</status>
         <midino>0x09</midino>
         <group>[Channel1]</group>
         <key>hotcue_1_clear</key>
         <description></description>
         <options>
          <normal/>
         </options>
        </control>
        <control><!-- LC2 Clear -->
         <status>0xB0</status>
         <midino>0x0A</midino>
         <group>[Channel1]</group>
         <key>hotcue_2_clear</key>
         <description></description>
         <options>
          <normal/>
         </options>
        </control>
        <control><!-- LC3 Clear -->
         <status>0xB0</status>
         <midino>0x0b</midino>
         <group>[Channel1]</group>
         <key>hotcue_3_clear</key>
         <description></description>
         <options>
          <normal/>
         </options>
        </control>
        <control><!-- LC4 Clear -->
         <status>0xB0</status>
         <midino>0x0C</midino>
         <group>[Channel1]</group>
         <key>hotcue_4_clear</key>
         <description></description>
         <options>
          <normal/>
         </options>
        </control>

When I hit these buttons without holding shift, they register as status 0x90 buttons. If I hold shift, they go into the controller as 0xB0 status buttons. I have the buttons mapped as such but they do not function, still. Stranger yet, the Shift button and Microphone button have midiDebug outputs that look like this:

Shift button pressed, not released:

Debug [PM 3. DJConsole Rmx2 MIDI 1]: "3. DJConsole Rmx2 MIDI 1: [F0 00 01 4E 0E 06 02 00 00 00 01 00 00 00 F7 90 30 7F 00]"
Warning [PM 3. DJConsole Rmx2 MIDI 1]: MidiDevice: No MIDI Script function found for "3. DJConsole Rmx2 MIDI 1: [F0 00 01 4E 0E 06 02 00 00 00 01 00 00 00 F7 90 30 7F 00]"

Now, the buttons do have 3 byte MIDI messages, but they are randomly sent, meaning that the 3 byte sequence is unreliable, it does not always register or get sent. Somehow it mysteriously doesn't happen. However, the above weird message *does* always happen. I don't know how to map it, though.

OS: Ubuntu Linux 10.04
CPU: Intel Pentium (using a Dell Inspiron 1545, I believe)
All hardware is stock.
Controller: Hercules DJ Console RMX 2
Steps to reproduce the problem: Press and hold shift and press the pads in cue mode.

Revision history for this message
Sean M. Pappalardo (pegasus-renegadetech) wrote :

That message from the shift key is a System Exclusive (SysEx) message with a standard 3-byte Note On message tacked on the end. Check your controller's documentation to see what it's supposed to send when you press Shift.

I had been working with ALSA developers to have a SysEx message sent when a controller tries to use non-standard MIDI bytes (0xF9 in particular,) but the standard note-on should not be there (rather sent as a separate message) so a bug will need to be filed with the ALSA MIDI team once you find out what your controller is actually sending.

You can handle the SysEx message now though by following the information I just added to the wiki: http://mixxx.org/wiki/doku.php/midi_scripting#system-exclusive_message_handing_functions

Revision history for this message
Circuitfry (c-7) wrote :

Gotcha. I think I've got it scripted right (I followed the exact instructions for the MIDI xml)

/* [ Function inboundSysex ] - Version 0.1.4
  * Partially operates. If I can't get this to work, shift is fucked.
*/
DJCRMX2.inboundSysex = function (data, length){
 if(data[0]==0xF0) // If a Sysex function has passed...
 { // If the function is the microphone button.
  if(data[6]==0x0D && data[10]==0x01) // If pressed
  {
   engine.setValue("[Microphone]","talkover",1);
  }
  else if(data[6]==0x0D && data[10]==0x00)
  {
   engine.setValue("[Microphone]","talkover",0);
  }
 }
}

I mean I'm testing an array of bytes, so this should work, but I'm still running into trouble. Furthermore, Shift+Pads send a status 0xB0 message instead of the regular 0x90 message, and I have them mapped in the XML, but the commands still do not happen. Daschuer picked up one of these controllers so maybe we can get the details worked out. Thanks for the help so far, Pegasus, the tutorial videos really did help a lot with the mapping.

Revision history for this message
Daniel Schürmann (daschuer) wrote :

I cannot reproduce the original problem with
Ubuntu Precise 32 bit
Alsa 1.0.25+dfsg-0ubuntu1.1
Mixxx 1.11.0-pre r3776

The SysExId of my RMX 2:
amidi -p hw:1,0,0 -S F07E7F0601F7 -d
F0 7E 00 06 02 00 01 4E 02 00 0E 00 13 00 00 00 F7

The "Mic On/Off" Button works very reliable
Debug [Controller]: "DJConsole Rmx2 MIDI 1: 15 bytes: [F0 00 01 4E 0E 06 0D 00 00 00 01 00 00 00 F7]"
Debug [Controller]: "MIDI status 0x90 (ch 1, opcode 0x9), ctrl 0x48, val 0x7F"
Debug [Controller]: "DJConsole Rmx2 MIDI 1: 15 bytes: [F0 00 01 4E 0E 06 0D 00 00 00 00 00 00 00 F7]"
Debug [Controller]: "MIDI status 0x90 (ch 1, opcode 0x9), ctrl 0x48, val 0x00"

What is your Setup?

One other thing:
The Mic "On/Off" button seems to be hard wired with the RMX2 Mic jack.
Will it be possible to remote control it by Mixxx or should we simply ignore the Mic "On/Off" button within the mapping?

Revision history for this message
Daniel Schürmann (daschuer) wrote :

Your DJCRMX2.inboundSysex solution works also like a charm.

RJ Skerry-Ryan (rryan)
tags: added: controllers
Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

So, since Daniel can't reproduce:

1) Ubuntu 12.04 includes a version of ALSA MIDI which fixes this?
2) circuitfry has a different firmware revision than Daniel?

@circuitfry -- do you still use Lucid? If you've upgraded, could you confirm the issue is fixed with a newer ALSA?

Changed in mixxx:
importance: Undecided → Low
status: New → Triaged
milestone: none → 1.12.0
RJ Skerry-Ryan (rryan)
Changed in mixxx:
status: Triaged → Incomplete
Changed in mixxx:
status: Incomplete → Invalid
Revision history for this message
Swiftb0y (swiftb0y) wrote :

Mixxx now uses GitHub for bug tracking. This bug has been migrated to:
https://github.com/mixxxdj/mixxx/issues/6942

lock status: Metadata changes locked and limited to project staff
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.