Thanks ! I’m trying the solution you provided, it seems to work. Here’s what I have so far, script 5 writes the length of the recorded loop in PN 0 then PN 1 is the current position in ms (it starts playing, looping as soon as the button is released) and PN 2 is the position of the fader It’s not fully optimized but each fader moves/loops from 0 to 15 at its own speed.
M:
SCRIPT 1; SCRIPT 2
I:
G.FDR 0 0 0 16 1 2 0 3
G.FDR 1 0 1 16 1 2 0 4
G.BTX 0 0 2 1 1 1 0 5 2 1
M! 2; INIT.P.ALL
1:
J PN 1 0; K PN 0 0
PN 1 0 WRP + J LAST $ 0 K
PN 2 0 / PN 1 0 / K 16
G.FDR.N 0 PN 2 0
2:
J PN 1 1; K PN 0 1
PN 1 1 WRP + J LAST $ 0 K
PN 2 1 / PN 1 1 / K 16
G.FDR.N 1 PN 2 1
5:
J G.BTNI
IF G.BTNV: PN 0 J 0
IF EZ G.BTNV: PN 0 J LAST $
// (not connected to ER-301 yet)
Edit: I’ve added the code for two asynchronous faders and two (latch) buttons for recording/playing. I’m not sure what I’m going to do now : reverse or speed change, I’ll try. At least the first goal (visualizing two asynchronous loops on a grid) is reached
/ video for info.
Another version with speed control and reverse (work in progress^^)
#1
J PN 1 0; K / PN 0 0 A
PN 1 0 WRP + J LAST $ 0 K
PN 2 0 / PN 1 0 / K 16
G.FDR.N 0 PN 2 0
#2
J PN 1 1; K / PN 0 1 B
PN 1 1 WRP + J LAST $ 0 K
PN 2 1 / PN 1 1 / K 16
G.FDR.N 1 PN 2 1
#3
#4
#5
J G.BTNI
IF G.BTNV: PN 0 J 0
IF EZ G.BTNV: PN 0 J LAST $
#6
#7
IF EZ G.FDRV: BRK
IF == G.FDRI 2: A G.FDRV
IF == G.FDRI 3: B G.FDRV
#8
#M
SCRIPT 1; SCRIPT 2
#I
G.GFX 0 0 0 0 16 1 2 0 3 1 2
G.BTX 0 0 2 1 1 1 0 5 2 1
G.GFX 1 2 4 2 5 1 2 0 7 2 1
M! 2; INIT.P.ALL; G.GFDR.N 1 2
G.GFDR.RN 1 -2 2; G.FDR.PR 2 4
G.FDR.PR 3 4