seq for 3sis using asl functions + freq modulation
| --- HOJE by @glia based on TONIGHT by @jlmitch5 | |
| -- output 1 > 3sis CENTRE inlet | |
| -- output 2 > FREQ inlet | |
| -- output 3 > HIGH inlet | |
| -- (optional) connect LOW outlet to FM inlet + output ALL | |
| seq = { 0, 4, 5, 7, 9, 2, 4, 7, 0 } | |
| step = 2 | |
| switch = 1 | |
| a = math.random(2,8) | |
| b = math.random(3,10) | |
| c = math.random(1,6) | |
| level = 10 | |
| time = 2.2 | |
| function init() | |
| output[1]( loop { rtm | |
| , to(function() return level/a end, function() return time/b end) | |
| , rtm | |
| , to(function() return -level/c end, function() return time/a end) | |
| , rtm | |
| , to(function() return -level/b end, function() return time/c end) | |
| , rtm | |
| , to(function() return -level/a end, function() return time/b end) | |
| } ) | |
| output[3]( loop { rtm | |
| , to(function() return level/a end, function() return time/b end) | |
| , rtm | |
| , to(function() return -level/c end, function() return time/c end) | |
| } ) | |
| end | |
| function rtm() | |
| output[2].volts = seq[step]/12 | |
| output[2].slew = math.random(0,3)/100 | |
| step = ((step + math.random(0, 2)) % #seq) + 1 | |
| if step == 1 then | |
| switch = (switch + 1) % 2 | |
| if switch == 1 then | |
| a = math.random(2,8) | |
| b = math.random(3,10) | |
| c = math.random(1,6) | |
| end | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment