diff options
| author | sbahling <sbahling@mudgum.net> | 2018-10-31 23:31:20 +0100 |
|---|---|---|
| committer | sbahling <sbahling@mudgum.net> | 2018-10-31 23:31:20 +0100 |
| commit | 70ff37debca07c6711c104085df70c4124cde091 (patch) | |
| tree | 44fc07e04e03dcda3584ab0da8411454cd3b9477 /tascam_fw_console/console.py | |
| parent | 90f9b73aa0d2c09404511176bcc8640e235f2cbc (diff) | |
| download | tascam-fw-osc-70ff37debca07c6711c104085df70c4124cde091.tar.gz tascam-fw-osc-70ff37debca07c6711c104085df70c4124cde091.tar.xz tascam-fw-osc-70ff37debca07c6711c104085df70c4124cde091.zip | |
Handle incoming strip select notification
Diffstat (limited to 'tascam_fw_console/console.py')
| -rw-r--r-- | tascam_fw_console/console.py | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/tascam_fw_console/console.py b/tascam_fw_console/console.py index 319f969..97a89e9 100644 --- a/tascam_fw_console/console.py +++ b/tascam_fw_console/console.py @@ -257,10 +257,20 @@ class Console(): def default_handler(self, addr, *args): print(addr, args) + def strip_select_handler(self, addr, ssid, state): + strip = self.strips[int(ssid)] + print('select_handler', strip, state) + if strip.num == 0 or strip.name == ' ': + return + if state: + strip.select = True + else: + strip.select = False + def strip_mute_handler(self, addr, ssid, state): strip = self.strips[int(ssid)] print('mute_handler', strip, state) - if strip.name == ' ': + if strip.num == 0 or strip.name == ' ': return if state: strip.mute = True @@ -270,7 +280,7 @@ class Console(): def strip_solo_handler(self, addr, ssid, state): strip = self.strips[int(ssid)] print('solo_handler', strip, state) - if strip.name == ' ': + if strip.num == 0 or strip.name == ' ': return if state: strip.solo = True @@ -280,7 +290,7 @@ class Console(): def strip_recenable_handler(self, addr, ssid, state): strip = self.strips[int(ssid)] print('recenable_handler', strip, state) - if strip.name == ' ': + if strip.num == 0 or strip.name == ' ': return if state: strip.rec = True |
