Steve-Bome Forum Moderator
2018-05-01 14:55:09
Hi Karen,
Yes, however to give you a better idea of what you want, it would be helpful to know the outgoing actions you want to perform. You would set up a global variable to count the sequence number. Within rules, you add 1 until it reaches the desired maximum at which point you reset the counter to zero. Here is an example of sending different notes depending on the iteration of the counter. I could have easily used the same note and sent a different velocity value based on the iteration.
Incoming message: Note on note 60 on channel 1
Rules:
//increment counter
ga=ga+1
// If maximum is reached, set counter to 0
if ga > 10 then ga = 0
// Determine note value to send based on counter position
if ga==1 the pp = 60
if ga==2 then pp=61
… etc
Outgoing action Note on Channel 1 note pp velocity 127
Now if you want a completely different action on each iteration. Just set up a bunch of translators that monitor the same incoming message. You only increment the value on the first translator. Each translator monitors for the global variable and only fires its action if it belongs to that translator. So the first translator monitors for value of 1, the second value of two etc. The rules would look something like this:
// Rules for translator 1 monitors ga for value of 1
if ga!=1 then exit rules, skip outgoing action
// Rules for for second translator monitors ga for value of 2
if ga!=2 then exit rules, skip outgoing action
In this way each translator could have it’s own and distinct outgoing action.
I hope this helps.
Steve Caldwell
Bome Moderator and
Independent Bome Programming Consultant/Specialist
bome@sniz.biz
karan-walia
2018-05-02 12:18:30
Hi Steve,
that was really helpful, thanks!!
Sounds good, will test it right away. I want to use this to execute different Apple Script, depending on the value of the variable/counter. So the second method should do the trick!
Steve-Bome Forum Moderator
2018-05-02 14:13:20
comment