Teletype workflow, basics, and questions

teletype

#282

Two ways i would think about doing that. Either way, store the note values and intervals in a pattern. Then either have a script play the note, advance the pattern, and call itself with the interval using DEL. Or, have the script called from the metronome, and have the script change the metronome interval.


#283

I just performed a show where I controlled three voices from the modular and played guitar. Thought this would be a good place to share how I used teletype to make that happen.

First, I tuned each of the voices to a pitch and kept that the same throughout the performance. I then took every song and found (up to) 4 notes that would randomly cycle (using the N operator) based off the root note of the voice that would be in key for each song. So the patterns look something like

// for song 1
0 2 3
2 5 3
6 8 3
7 2 0
// for song 2
1 4 5
4 7 6
3 2 0
8 2 0
// etc....

I then had a param knob that I scaled down to correspond to each of the 8 songs that were part of the set. I made use of RRAND to choose notes (1 + n) - (4 + n) of the pattern, where n was the knobs position multiplied by 4. In other words, for song 1, it would pick from notes 1-4, 2 from notes 5-8, etc.

I also used the position of the knob to pulse the trigger outputs (and thus flash the led) so that I could tell which position the knob was at rather than just guess. Trigger out 1 would flash for songs 1 and 5, 2 for songs 2 and 6, etc. I did this by using the modulo operator to “wrap” the sequence to the 4 leds I had access to. My param knob was 0-7, so ADD MOD PARAM 3 1 will convert that to 1-4 wrapping.

This LED flashing ended up being a really smart idea, because the knob I used was on the TXi, and had some i2c feeze-up a couple times. I knew if I didn’t see an led, I needed to power cycle! :slight_smile:


I’m glad I took the time to do this rather than try to manually tune the oscillators between songs (which would have been a lot more stressful). Before the next show I want to add some sort of calibration position to the param knob so that I can tune the oscillators and not be paranoid when transporting the system that a knob is going to get moved and mess things up!


#284

is there a simple way to have a trigger being sent to trigger input 1, be multed via software to the other trigger inputs? so every time script 1 is triggered, script 2 is also triggered, for example.


#285

just put

script 2

in your script 1. also, $ is an alias for script. so…

$ 2

would work as well.


#286

wow, duh! thanks so much :grin:


#287

my next stupid question of the week! :grin:

trying to work my way through creating a simple generative scene, and am using TOSS to randomly trigger a trigger output on or off. However, I want this trigger to be a short momentary trigger, as opposed to the output being turned ON, then held on until it is next turned off. I thought about using the DELAY and IF commands to make it so whenever the trigger is turned on, there is a set delay and then it is turned off again, but when putting these on the same line I get “mod not allowed here.”


#288

Sorry misunderstood the question.


#289

EDIT: try TR.PULSE!


#290

Question about audio rate stuff. If I wanted to XOR two signals, how far into audio rates would the Teletype go? I’m getting a Teletype soon.
I have a few modules that Im wondering if I could replicate. The Benjolin I tend to use at modulation frequencies for its Rungler anyway (XOR and Shift register). I also use a Doepfer PLL for its phase comparator function quite a bit (XOR or RS flip flop based). If I replicated the functionality in a script and then triggered that with a square wave is there any limitations or dangers to the module?


#291

mmmm, you’d have to use METRO at the fastest rate, (once every millisecond) to do this, I think? so the fastest purely theoretical sample rate is 1kHz, not counting whatever computation Teletype would have to do at that rate so… not that fast.

The problem is that doing computation at the limits you might find that the timing isn’t accurate enough for your liking? I doubt you could seriously damage the module, but I’m not an expert.


#292

Using an external square wave to trigger script 1 would be faster than using the metro script, wouldn’t it?


#293

oh you know what, you’re probably right. I guess the sampling time of IN might end up being the limiting factor in that case


#294

@alanza @rikrak Thanks! Ordered a Teletype this morning :slight_smile:


#295

I have a question about DRUNK and setting bounds for it. I know that there’s MIN, MAX, and WRAP operators but in the third study the following is used to achieve the same purpose: MOD DRUNK 5. I’m confused because from what I understand DRUNK 5 will return 4, 5 or 6 but MOD takes two operands. I’m sure I’m just missing something syntax-wise but if anyone could provide clarity on this I’d appreciate it!


#296

MOD takes two values: one, a number (here the output of DRUNK) and the second a divisor, 5. It outputs the remainder of dividing the first by the second, so you’ll get a number between 0 and 4. As you say, there are other ways to accomplish this.

DRUNK typically takes no operands


#297

Ohhh gotcha I was forgetting that in the case that DRUNK returns -1 it would set the value of DRUNK to 4. I also forgot that each time you call DRUNK it resets the value, thanks for clearing that up!


#298

Trying my first Teletype script. Getting an error “Mod not allowed here: DEL” so I’ve stripped it back to:

L 1 8 : DEL I : TR.PULSE 1

Which is still giving the error. Can I not put a DEL command inside a loop like this? Or is the syntax incorrect?


#299

Can’t nest any PRE mods unfortunately! ie, one colon per line. But if you want compound behavior like shown, you call call another script from the first loop.


#300

Ok thanks! Can I be read from a secondary Script that is being called within a Loop? Doesn’t seem to work. I guess I could use the O variable in the secondary script


#301

sounds like you’re on firmware version 2.2. starting with 2.1 each script has its own I variable, so if you want to pass its value to a script called from a loop you’ll need to use another variable, like this: L 1 8: T I; SCRIPT 2, then in script 2 you can do DEL T: ...

starting with v3.0 (currently in beta) when a script is called from another script I gets initialized with the I value from the calling script, so you won’t have to use an extra variable anymore.