Skip to content

Commit

Permalink
Experimental (totally untested) Push2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
tomduncalf committed Dec 13, 2015
1 parent c42e3b3 commit 18b6045
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 1 deletion.
File renamed without changes.
27 changes: 27 additions & 0 deletions Devices/Push2/__init__.py
@@ -0,0 +1,27 @@
# Embedded file name: /Users/versonator/Jenkins/live/output/mac_64_static/Release/python-bundle/MIDI Remote Scripts/Push2/__init__.py
from __future__ import absolute_import, print_function

from Ubermap import UbermapDevicesPatches

def get_capabilities():
from ableton.v2.control_surface import capabilities as caps
return {caps.CONTROLLER_ID_KEY: caps.controller_id(vendor_id=10626, product_ids=[6503], model_name='Ableton Push 2'),
caps.PORTS_KEY: [caps.inport(props=[caps.HIDDEN, caps.NOTES_CC, caps.SCRIPT]),
caps.inport(props=[]),
caps.outport(props=[caps.HIDDEN,
caps.NOTES_CC,
caps.SYNC,
caps.SCRIPT]),
caps.outport(props=[])],
caps.TYPE_KEY: 'push2',
caps.AUTO_LOAD_KEY: True}


def create_instance(c_instance):
from .push2 import Push2
from .push2_model import Root, Sender
root = Root(sender=Sender(message_sink=c_instance.send_model_update, process_connected=c_instance.process_connected))

UbermapDevicesPatches.apply_ubermap_patches()

return Push2(c_instance=c_instance, model=root)
4 changes: 3 additions & 1 deletion Devices/install.command
Expand Up @@ -16,6 +16,7 @@ cd ${0%/*}

# Backup
cp_if_ne "$LIVE_MIDI_REMOTE_PATH/Push/__init__.pyc" "$LIVE_MIDI_REMOTE_PATH/Push/__init__.pyc.ubermap-backup"
cp_if_ne "$LIVE_MIDI_REMOTE_PATH/Push2/__init__.pyc" "$LIVE_MIDI_REMOTE_PATH/Push2/__init__.pyc.ubermap-backup"

# Copy
mkdir -p "$LIVE_MIDI_REMOTE_PATH/Ubermap"
Expand All @@ -24,7 +25,8 @@ cp ../Common/configobj.py "$LIVE_MIDI_REMOTE_PATH/Ubermap/"
cp ../Common/UbermapLibs.py "$LIVE_MIDI_REMOTE_PATH/Ubermap/"
cp UbermapDevices.py "$LIVE_MIDI_REMOTE_PATH/Ubermap/"
cp UbermapDevicesPatches.py "$LIVE_MIDI_REMOTE_PATH/Ubermap/"
cp __init__.py "$LIVE_MIDI_REMOTE_PATH/Push/"
cp Push/__init__.py "$LIVE_MIDI_REMOTE_PATH/Push/"
cp Push2/__init__.py "$LIVE_MIDI_REMOTE_PATH/Push2/"

# Copy config
mkdir -p ~/Ubermap/Devices
Expand Down

0 comments on commit 18b6045

Please sign in to comment.