aha, that is where this is breaking down for me. so the four pulses essentially overlap one another, whereas my expectation was that one would finish then another would begin. thanks!

1 Like

playing with the stack command, it puts me in a similar situation as the loop. this may be overly difficult without having the ability to write a ‘del’ command into a loop or stack.

You can use the M script to pop items off the stack. So when you want to “schedule” 4 triggers, you push them on the stack then set the metronome period and enable the M script, which will disable itself when the stack is empty.

yeah, that does seem to be one way to do this. thanks!

You can say DEL 250 : S.POP I think. Haven’t tried it.

Edit:
Maybe L 1 4 : DEL MUL 250 I : S.POP would do it. I don’t know, I’m pretty new to teletype.

Much to learn about timing in this thread:

1 Like

Can’t nest PREs, I think.

Which means that your solution is easier, as you can’t even put things on the stack in a loop.

4 lines for 4 triggers, I’m afraid.

Once I get my hands on mine I’m going to have a look at the codebase to see what can be done to allow teletype to be a little more flexible and terse. Maybe a loop + del macro?

1 Like

yeah I was thinking that being able to call the del command inside a loop might be a simple resolution to this.

alternatively, some sort of new ‘ratchet’ command could fulfill the same purpose.

Likely, to extend the software to support nested prefixes would be a little complicated, not to mention verbose.

It would be simpler to create macros to do fixed things in software, like:

LD [x] [y] [delay] : [command]
for loop + delay, assuming [delay] can be an expression that includes I

or:
LS [x] [y] : [command]
for loop + stack push

2 Likes

how about

M

S.POP

1

L 1 4 : SCRIPT 2

2

DEL 250 : TR.PULSE 1
3 Likes

thanks, i can try this in a bit. what purpose does the stack serve here?

edit: running that and triggering script 1 gives the same results as before-- what i presume are four overlapping pulses.

Wouldn’t this schedule 4 triggers, all 250ms from now, instead of 4 triggers 250ms apart? Also, the M script does nothing (there are no stack pushes).

So maybe

1
X 0
L 1 4 : SCRIPT 2

2
DEL MUL 250 X : TR.PULSE 1
X ADD X 1

(Still getting used to polish notation. Used RPN for years so old habits make for syntax errors)

4 Likes

that seems to be it. in this case i believe the first MUL value cannot be faster than the TR.TIME value.

2 Likes

good catch! that looks to be the solution.

here’s a slight edit to the above for usability. this goes nice with the mutable instruments rings module running with 4 notes in the sympathetic strings mode-- can make harp or acoustic guitar playing sounds. editing the TR.TIME value gets you different playback rhythms and the CV line would probably be better using values as a melody instead of random semi tones, but for the sake of example …

1
X 0
Y ADD TR.TIME A 1
L 1 4 : SCRIPT 2

2 
Z MUL X Y
DEL Z : CV 1 N RAND 24
DEL Z : TR.PULSE A
X ADD X 1

one thing i notice is that i can’t loop this beyond 4 steps. interestingly, removing the CV line gets me to 8 steps, but nothing beyond that. this isn’t very problematic for me, but if someone is into debugging, it might be interesting to find out why the loop doesn’t go past 4 or 8.

4 Likes

The DEL stack is only 8 deep.

#define DELAY_SIZE 8

1 Like

Which makes me wonder: what’s the memory landscape on this project? I’d be interested in playing with a deeper stack, deeper delays, other pattern configurations. Off-the-cuff: how much wiggle room is there?

is that global across the whole scene?

Yeah, 8 delay slots total.