| 1 |
# OLA Trigger Config to control itunes |
| 2 |
# See https://wiki.openlighting.org/index.php/OLA_DMX_Trigger |
| 3 |
# Copyright (C) 2011 Simon Newton |
| 4 |
|
| 5 |
# Variable definitions |
| 6 |
############################################################################### |
| 7 |
itunes_action='' |
| 8 |
|
| 9 |
|
| 10 |
# Triggers |
| 11 |
############################################################################### |
| 12 |
# Slot Values Action |
| 13 |
|
| 14 |
# The first slot selects the action |
| 15 |
1 1 itunes_action='play' |
| 16 |
1 2 itunes_action='pause' |
| 17 |
1 3 itunes_action='previous track' |
| 18 |
1 4 itunes_action='next track' |
| 19 |
|
| 20 |
# Sending non-0 on the second slot will run the action |
| 21 |
2 1-255 `osascript '-e' 'tell application "iTunes"' '-e' '${itunes_action}' '-e' 'end tell'` |