(Teletype) expanding scripts: length and amount

Hi there,
Just started with my new Teletype this week and ‘discovered’ that a script only can hold 6 lines of code…
Is there a specific reason for this limitation please?
Any chance for future updates with longer scripting possibilities?

Hey Pascal. I believe the 6 line limit is there purely so that there is no need to scroll to see the whole script.

Don’t forget that you can call a script from within a script and even load an entire scene of scripts from within a script!

1 Like

Hi @rikrak,
OK, thanks.

If it is only a esthetical issue, I would prefer more lines of code and scrolling, like in pattern pages :wink:

I did not try the loading of a scene from within a script yet, I suppose the new scene replaces the first one and the scripts of the first scene are lost?

I’m pretty sure it’s not only aesthetic; it’s a deliberate design decision in the Teletype language. Teletype makes a preference for small self-contained scripts that reference each other, rather than long imperative code. The ease-of-use argument - a script should always be visible in its entirety - starts to give way to other arguments (a script is more like a ‘function’ than a ‘program’; a ‘scene’ is more like a program)

What are you trying to do that needs so many lines?


For the moment I am just discovering the module.
But this 6 line limitation struck me a bit, especially if it would be an esthetical issue.
I can easily imagine some coding that would exceed these 6 lines, even with the ;-option now and even with total of 6x8 (scripts) lines :blush:

I don’t mind the 6 line limit.
But I do think that adding another ‘layer’ of scripts would be useful in a number of situations, especially if one has Telex units attached to TT. I know there was some talk of implementing a set of ALT scripts, but I don’t think it moved forward.

1 Like

I love the 6-line limit! There’s a lot of fun to be had, working out how to squeeze your 20 lines of code in to 6! It often leads to an interconnectedness that wouldn’t have otherwise arisen.


I don’t mind the 6 line limit but I would love to see another layer of scripts. Especially if they could be named!

If you have one of the latest firmwares (and you should upgrade if you don’t), you can use a semicolon to fit in multiple statements per line. For example:

C 18

Can be compacted to:

A PARAM; B RAND 48; C 18; D IN

Also, some commands have aliases that make things even shorter. For instance, PARAM in the script above can be shortened to PRM. The math aliases are super-handy. All should be contained in the latest documentation up on the TT pages at monome.


extra layers of scripts is an idea, they could be activated then from within the existing 8 ones…
simply calling them scripts A, B, C, D…Z?

the only thing about calling scripts from within scripts is a bit the nesting stuff going on, it could become quite complex and disordered quickly…

I would like to keep a distinct functionality per script, so extending the length of 6 lines into a variable scrollable length would be more my kind of thing…

Can you give us concrete examples of things that the 6 lines limit prevent you to do?
I think that after a few days with your TT you will be able to do more than you can imagine (expect?) within those 6 lines… :wink:

1 Like

But, as you say yourself, you’ve only been Teletyping a week. It feels like you’re bringing a desired style of programming to the object, rather than coming to it on its own terms?

Again: concrete examples of things that run into this limit are useful, as the many TT users on the forum (not to mention the lively Teletype Code Exchange thread) would almost certainly be able to offer input or suggestions.


OK, thanks, as a newbie to the Teletype, temporarily accept the limitation, will let you know in this thread about specific limitations when they occur :slight_smile:


As it is now, you can call scripts from within scripts already. So the dangers of infinite loops had been addressed.

Here’s a concrete example: I’m trying to use an init script to generate scales mathematically. I want to loop through and fill patterns with scales and generated note values. However, I can’t possibly do it in six lines. This leaves me to write a program on my computer to calculate the HZ values for each note and type them in manually. If I want to do that 256 times, it’s definitely a pain. I think the Teletype would benefit a lot from more variables, longer scripts, and structures like arrays which could be shuffled and reorganized.


how do you calculate them?
one way to extend the limit is by calling another script.

calling another script is an option, but you loose a gate input by doing so…

I was able to do it by using note values and calculating things separately (in Ruby, some leftover scripts from my monome 64 days - how I wish it would connect to Ansible!). I just took my time and typed them into the pattern tracker.

See, I’m a newbie, starting to get the hang of shorter code and calling things.:baby: But as a programmer, I do long for more control, loops with multiple lines, arrays, longer scripts. In the write preset window, I can scroll many lines, so the esthetics argument seems a bit silly to me.

I do love the Teletype but it’s kind of a shame it’s so limited. I start to appreciate that it’s opinionated, and I have to work through puzzles each time I want to accomplish a new project - which leads, of course, to happy accidents :slight_smile:

Maybe I’ll take a look at the firmware repo and get inspired for a pull request? Or perhaps there’s limitations due to memory and hardware?

Thanks @scanner_darkly for the suggestions!

1 Like

You should consider making your own custom operators if there are things that you want to do regularly that could be abstracted/factorized that way easily…

1 Like

i came to appreciate the limitations somewhat, imagine coming back to a 100 line script later and trying to understand what it does / edit it on teletype. i do think though that the limitations often force you to make things less readable. personally i’d love to see more scripts and/or longer scripts, more variables and pattern banks (arrays would be nice too, patterns do cover that territory somewhat though). tt is a balancing act though, so power vs simplicity has to be carefully considered.

if you’re comfortable with setting up the toolchain i’d totally go for modding it yourself, there might be some memory/hardware limitations (tbh not sure how much room we have), i’d just try it and see if it works.

monome 64 - does it not work with ansible at all? not sure if all editions do. if it’s a model supported by libavr32 you could also use it with teletype with the upcoming 2.3 version (you do need to power it externally).