![]() |
![]() ![]() ![]() ![]() ![]()
|
next newest topic | next oldest topic |
Author | Topic: switches as controllers | |
Bill Meadows Member |
![]() ![]() ![]() Would someone figure out how to do this? I'm using buttons on a WiiMote to send MIDI controller messages to another program. I want two buttons to turn ON & OFF two different processes, so I have used e.g.: "!Button1 asToggle" in the value field of a MIDIOutputController. This works fine. The problem is that the two buttons must have the following relationship with each other: If the Button1 is ON, then Button2 can send ON/OFF messages. The part I can't figure out is if Button2 is ON and I turn OFF Button1, then when I turn Button1 back ON, Button2 is still ON. (I want Button2 to be OFF everytime Button1 turns ON.) The asToggle operator has memory, so hasChangedReset may be the better choice, but I can't make it behave as I want. (btw - I should also mention that the buttons must behave as toggles - press once for ON, press again for OFF - since they are on a WiiMote and I can only use my thumb.) [This message has been edited by Bill Meadows (edited 07 April 2009).] IP: Logged | |
SSC Administrator |
![]() ![]() ![]() Would this do it? !b1 asToggle (!b1 asToggle * !b2 asToggle) If the Button1 is ON, then Button2 can send ON/OFF messages. IP: Logged | |
Bill Meadows Member |
![]() ![]() ![]() quote: I got that far. The problem is that asToggle remembers the last state of b2. So if b2 is ON when b1 turns ON, it re-triggers the b2 process. It's hard to describe without being too wordy - the two buttons control two different processes. Here are the conditions: If process 1 is OFF, process 2 can NOT be turned ON. Meeting that last condition is what throws me. IP: Logged | |
pete Member |
![]() ![]() ![]() Hi Bill It's a bit involved but I think this is what you are looking for (!Trig2 +(1-!Trig1 asToggle)) countTriggersMod: ((!Trig1 asToggle)+1) and button one would be simply !Trig1 asToggle ---------------------------------------------------- Is this what you meant? hope it helps Pete [This message has been edited by pete (edited 07 April 2009).] IP: Logged | |
pete Member |
![]() ![]() ![]()
IP: Logged | |
Bill Meadows Member |
![]() ![]() ![]() Brilliant! Thanks Pete, that works perfectly. IP: Logged |
All times are CT (US) | next newest topic | next oldest topic |
![]() ![]() |
This forum is provided solely for the support and edification of the customers of Symbolic Sound Corporation.