User Tools

Site Tools


macros:example:midimachinecontrol

Example

MIDI Machine Control

by: Oliver Waits, December 2019/January 2020
published: here (he submitted this by email
description: macros to send some MIDI commands which control MMC-enabled devices
remarks: In order to run this over other ways than real 5pin MIDI Titan v13 is required

functions

The complete file with all commands/macros: midimachinecontrolmacros.xml

A file with additional macros to set MIDI timecode via MMC can be found here mmc_settimecode.xml

Code

MidiMachineControlShortlist.xml
<?xml version="1.0" encoding="utf-8"?>
<avolites.macros>
 
  <!-- MMC Stop -->
  <macro name="MMC Stop" id="Avolites.Macros.MMCStop">
    <sequence>
      <step>Panel.Midi.Send("F0 7F 7F 06 01 F7")</step>
    </sequence>
  </macro>
 
  <!-- MMC Play -->
  <macro name="MMC Play" id="Avolites.Macros.MMCPlay">
    <sequence>
      <step>Panel.Midi.Send("F0 7F 7F 06 02 F7")</step>
    </sequence>
  </macro>
 
  <!-- MMC Pause -->
  <macro name="MMC Pause" id="Avolites.Macros.MMCPause">
    <sequence>
      <step>Panel.Midi.Send("F0 7F 7F 06 09 F7")</step>
    </sequence>
  </macro>
 
  <!-- MMC Goto Start -->
  <macro name="MMC Goto Start" id="Avolites.Macros.MMCGotoStart">
    <sequence>
      <step>Panel.Midi.Send("F0 7F 7F 06 44 06 01 00 00 00 00 00 F7")</step>
    </sequence>
  </macro>
 
 
</avolites.macros>

Explanation

This explains the functional steps within the sequence. For all the other XML details please refer to Formats and syntax

Upon starting such a macro a predefined MIDI command is being sent. For the available commands see https://en.wikipedia.org/wiki/MIDI_Machine_Control however it depends from the device/software which commands are supported.

The GoToStart macro is an example how to alter this to a particular timestamp:

  • the message F0 7F 7F 06 44 06 01 00 00 00 00 00 F7 comprises of
    • F0 F7 ⇒ Universal Real Time SysEx
    • 7F ⇒ device ID. 7F is all devices
    • 06 ⇒ MIDI machine control command
    • 44 ⇒ GoTo
    • 06 ⇒ length (6 bytes to follow)
    • 01 ⇒ target (usually 01)
    • 00 00 00 00 00 ⇒ hours minutes seconds frames subframes (hexadecimal!)
    • F7 ⇒ end of Universal Real Time SysEx message

This way you can easily create your own macros to jump to a particular time: simply replace the 00 00 00 00 00 with the timestamp you want to jump to.

Various timestamps are used in the file mmc_settimecode.xml

How to use it

  1. for general information about using MIDI to control other devices see MMC - MIDI Machine Control
  2. depending from your setup you might need to use virtual MIDI patchcords like LoopMIDI or rtpMidi, see Software List
  3. sending out MIDI e.g. over USB or network is supported from Titan v13 on
You could leave a comment if you were logged in.
macros/example/midimachinecontrol.txt · Last modified: 2021/07/22 13:58 by 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki