dotherightthing / control-traktor

A collection of settings and Max4Live devices for improved control over Traktor Pro.
5 stars 0 forks source link
max4live

Control Traktor

A collection of settings and Max4Live devices for improved control over Traktor Pro.

Installation only

  1. Download release.zip from the latest Release
  2. Unzip/expand the folder and copy to ~/Music/Ableton/User\ Library/ (note: devices may be a mix of Audio/Instrument/MIDI types)
  3. See device usage instructions below (Rename Selected Track, Presample Selected Track)

Installation and development

This repo uses a build script so that I can write JavaScript in ES6 rather than ES5.

  1. Install Node and NPM and Git
  2. git clone this repo to ~/Music/Ableton/User Library/ (I also symlink this to my Websites folder so I can find it)
  3. Run npm install to install dependencies, run the build
  4. Run npm run watch to lint and build as you save file changes
    • Edit src/js/m4l-*.js - the Max-friendly (ES5) version of this file is updated in the dist folder
    • Edit dist/*.amxd in Max - this file is copied back to the src/patches folder
  5. Run npm run reinstall to recreate dist folder

Release

  1. Run npm run changelog
  2. Tag the latest commit with the message Bump version
  3. Push to Github and an action will run to generate a new Release

Control Traktor v5 (2024.01.08)

Description

Mackie MCU Pro

Stream Deck XL

When Settings > Remix Decks > Auto Enable Deck Play on Sample Trigger = unchecked, selecting a deck slot on the S8 changes the waveform but the Advanced Panel on the Remix Deck does not reflect the settings of the clip in the selected slot.

The streamdeck-clicker plugin automates mouse clicks on the 16 Remix Deck slots visible in the software, to ensure that the Advanced Panel on the Remix Deck exposes the per-slot controls and displays the settings relative to the clip in that slot.

Sidecar

I display Traktor on an iPad Pro12.9" 1 using MacOS Sidecar.

To remove black bars at top and bottom of display:

  1. Install https://github.com/waydabber/BetterDisplay
  2. Default setting: 164% - 1680x1050
  3. Change to: 100% - 1366x1024

Loopback

Deck D: Combining Ableton output with multiple external synths using loopback.

Using the Traktor Kontrol S8 audio device, one set of S8 inputs can be routed to one Deck input.

Using the S8 Loopback audio device in my licensed copy of Rogue Amoeba Loopback, any S8 input can be routed to any S8 output (e.g. Deck D), whilst all S8 mixer controls remain usable in Traktor. Additionally software synths and samplers in Ableton can be played using the CS1x and Push2 then sampled into Traktor via Deck D.

Note: there is a little noise from each of the S8 inputs, even if nothing is plugged in; this can be reduced relative to Traktor output by reducing the output level, but amounts below 50% reduce useful level meters and waveform amplitude in the remix decks.

Loopback Source: Channels Description Loopback Output Channels Loopback Monitors: Channels
Traktor Kontrol S8: 1/2 S8 Input A L/R (not currently used) - -
Traktor Kontrol S8: 3/4 S8 Input B L/R (not currently used) - -
Traktor Kontrol S8: 5/6 S8 Input C L (Monotron - mono) Channels 7 & 8 N/A - Traktor outputs to Master or Monitor
Traktor Kontrol S8: 7/8 S8 Input D L/R (CS1x - stereo) Channels 7 & 8 N/A - Traktor outputs to Master or Monitor
Traktor Kontrol S8: 9/10 ? - -
Pass-Thru: 7/8 Live - Output Config (Ext. Out) - 7/8 Channels 7 & 8 N/A - Traktor outputs to Master or Monitor
Pass-Thru: 9/10 Traktor Output Routing - Output Master Channels 9 & 10 Traktor Kontrol S8: Channels 1 & 2
Pass-Thru: 11/12 Traktor Output Routing - Output Monitor Channels 11 & 12 Traktor Kontrol S8: Channels 3 & 4

Screenshots:

Tips

Traktor Step Sequencer workflow

Beatgridding

To half or double BPM of track on the fly, disable Lock then use BPM /2 or BPM x2 on Streamdeck.

How To Beat Grid

Note: Shift + Cue always jumps to start of track, not first cue point

Loading new Loop Recorder recordings

Loading a recording into a Deck rather than the Remix Deck provides access to the Freeze function to trigger different parts of the loop.

Unsure of exact steps, but these two actions seem to prompt Traktor to update the list for a Library Favourite folder:

  1. Load the recording to a remix deck slot
  2. Change to a different Library Favourite folder, then change back

MIDI Sync

If a MIDI clip in Ableton drifts out of phase sync with Traktor, an alternative to pressing Clock Sync is to adjust the clip's Start Offset on Push2.

Control Traktor v4 update (2024.01.05)

Description

Control Traktor v4 (2023.10.10)

Description

Files

Setup

Traktor controls

Added

Removed

Usage tips

Misc

Drum Racks

Hot Cues
Freeze Slices
Loop Recorder

Live Input

Devices

Params

Remix Deck

Soundcard/keyboard


Control Traktor Deck v3 (2023.04.23)

Description

Files

Setup

Live

Traktor controls

Dev notes

Initial experiment

and

and

Solution

Issues

TODO

Usage tips


Control Traktor Deck v2

Status

Files

Description

When using Traktor in unconventional ways, multiple controllers can be involved. This requires setting up a .tsi file for each controller in order to map specific controls to Traktor.

This is fiddly and the work needs to be done again when controllers change.

This patch exposes the Traktor controls that I use in my DJing workflow, so that I can easily map my controllers using Ableton Live rather than Traktor.

The same device is used for Deck A and B, the only difference will be the output channel as per the mappings in the TSI file:

Set MIDI To to:

Usage

  1. Traktor > Preferences > Controller Manager > Import > m4l-control-Traktor-deck.tsi
    • In-Port: Traktor Virtual Input
    • Out-Port: Traktor Virtual Output
  2. add Control Traktor Deck.amxd to a MIDI track in Ableton Live (see my Traktor Live v3 template)
    • map controllers to the controls on the device

Roadmap

See https://github.com/dotherightthing/control-traktor/labels/Control%20Traktor%20Deck


Drum Rack To CC Hot Cue Sequencer (2023.02.09)

Files

Dev notes

Initial experiment

Traktor
Live
Push 2
Thoughts

That was pretty easy to set up, but the UX is pretty bad unless you're interacting with Live directly.

It would be better if I could either

Solution

Issues
TODO

Presample Selected Track

Files

Description

When jamming with soft synths or hardware synths, MIDI notes are driving that synth. Recording into the instrument channel would therefore record the MIDI input rather than the audio output. When recorded MIDI is played back at a later date, the sound is often different to what was originally played, due to some combination of synth settings not being saved with the MIDI input (this is especially the case with hardware synths). In this instance it's better to capture the audio output rather than the MIDI input. For synths that don't have MIDI input, audio capture is the only option.

On the Push2, creation of a track-based audio (or MIDI) resampling track necessitates multiple button presses and two hands. This interrupts the creative flow as it requires extensive hand-eye coordination:

  1. Press 'Mix'
  2. Press 'Mix'
  3. Press to select 'Input & Output'
  4. Scroll to select 'Input Type'
  5. Press Record + Track Select
  6. Rename new track in software
  7. Recolour new track

Key/MIDI mapping the Insert before and Insert after buttons automates this process, by:

  1. inserting a new track BEFORE (to the left of) or AFTER (to the right of) the selected track
  2. matching the type of the new track to the type of the selected track (Audio or MIDI)
  3. setting the input of the new track to the name of the selected track
  4. arming the new track
  5. naming the new track to indicate the source name and the time of creation
  6. recolouring the new track to match the selected track's colour
  7. returning the focus to the selected track

Recording can now be started via a single button press on the desired clip slot.

Note: This patch is functionally similar to ClyphX Pro's INSAUDIO/INSMIDI.

Usage

  1. add Presample Selected Track.amxd to the Master Audio track in Ableton Live
    • map button on Push2 or other controller to Insert before and/or Insert after button
  2. select an Audio, MIDI, or Instrument track
    • push mapped button from (2) to insert a resampling track
    • alternatively use Mira to view the Mira frame on an iPad, then tap one of the (Mira) buttons to insert a resampling track

Roadmap

See https://github.com/dotherightthing/control-traktor/labels/Presample%20Selected%20Track


Rename Selected Track

Files

Description

When jamming it's easy to lose track of what each track represents. This function provides a quick way to name the track from a list of common options.

Usage

  1. add Rename Selected Track.amxd to the Master Audio track in Ableton Live
    • map tabs object to encoder on non-Push controller
  2. select an Audio, MIDI, or Instrument track
    • turn mapped encoder from (2) to change the track name and see it update instantly
    • alternatively use Mira to view the Mira frame on an iPad, then tap a tab (option) on Mira to change the selected track name
    • alternatively lock Push to the device on the Master track, and turn the TRACKNAME encoder

Roadmap

See https://github.com/dotherightthing/control-traktor/labels/Rename%20Selected%20Track


Thanks to

Tip: Search a YouTube video for 'Push': Click 3 dots > Show transcript > Search in video

Insights

Passing variables to the JavaScript file

Technique A: Arguments

Patcher:

[live.tab] # UI object sending input to script
  | | |
    |
  [js script-name.js] # js object containing script (see list of tested variations below)

JS:

function bang()
  if (jsarguments.length > 1) {
    post(jsarguments[0]); // script name
    post(jsarguments[1]); // first argument
  }
}

I couldn't figure out how to use a dynamic value with this approach, as when a value is sent into the js object's inlet, it is treated as a function name rather than a string argument. That generates an error as there is no matching function.

js: no function argName [script-name.js]

This error can be mitigated by adding an anything() function:

function anything() {
  console.log(jsarguments.length);
  console.log(jsarguments[0], jsarguments[1]);
}

However I still couldn't figure out how to pass in a reference to the Symbol value generated by the middle outlet of live.tab:

js script-name.js              => anything() => script-name.js, <undefined>
sprintf js script-name.js %s   => anything() => no output
prepend js script-name.js      => anything() => no output
js rename-selected-track.js $1 => anything() => script-name.js, $1
js rename-selected-track.js $s => anything() => script-name.js, $s

Links:

Technique B: Listeners

Patcher:

[live.tab] # UI object to listen to in script + named  (via the Scripting Name field?)

[live.button] # live.button object to send bang
  |
[js script-name.js] # js object containing script

JS:

function bang() {
  // Run garbage collection
  gc();

  // Target object from patcher
  const obj = this.patcher.getnamed('namedObject');

  // Assign listener
  const ml = new MaxobjListener(obj, objCallback);

  // Get the current value
  post(ml.getvalue());
}

// When the listener detects a change, fire a callback
function objCallback(data) {
  // Get the latest value
  post(data.value);
}

Issues:

When the object has multiple outlets, you can't choose the one with the data type you want. For the live.tab object, I wanted the middle outlet (string Symbol) not the left outlet (Item Index). The latter would have only been useful if had access to the object's enum so I could get the string that the index referred to.

Links:

Technique C: Global functions

As the above two techniques didn't work for me, I settled on using global functions. This encouraged me to merge several separate scripts into one, and then to hide helper functions using privateFunctionName.local = 1.

Patcher:

[live.tab] # UI object sending input to script
  | | |
    |
[functionName $1] # message object containing function to call + variable argument
    |
  [js script-name.js] # js object containing script containing function

JS:

function functionName(arg) {
  post(arg);
}

Links:


Inspector: Bang when Transition from

For buttons (live.text) MIDI mappable controls should activate on mouse down AND mouse up, to prevent 2 clicks being required to repeat the action.

For buttons (live.text) Mira-only controls should only activate on transition from zero to one, otherwise every touch would trigger the action twice.


Mira

Mira supports

Mira does not support

Links