Skip to content

The Machine and the Piece

Where a setting lives follows from what kind of fact it is, and there are only three kinds:

What it isWhere it goesTravels with the project?
A fact about this machine — which audio interface, which MIDI ports, where your kits and plugins are~/.resonon/preferences.tomlNo — and it must not
A fact about this piece — which packages it draws on, which kits came from outside itresonon.toml in the projectYes
An operational knob — CI, headless rendering, benchmarksA CLI flag, an environment variable, or a VSCode settingn/a

That is the split every DAW makes between its Preferences and its project folder. Live has one Preferences dialog; so does resonon, and it is a file.

The rule underneath it: a setting anything outside the running session needs to know is data. The editor, resonon collect, resonon kits list and the plugin scan all need to know where your content is, and none of them runs your code. A folder named by a function call only exists while something is running that call, so everything else was guessing.

~/.resonon/preferences.toml

Read before any of your code runs, so the device comes up right the first time rather than coming up wrong and being reopened. Every key it takes is listed in Preferences.

Your piece then holds channel numbers and kit names only, so it travels:

set_project_title("my_song");
set_bpm(120);
master >> Output(0, 1);
let vocals = AudioTrack("vocals");
vocals.set_input(0);

Omit the file entirely and resonon uses the system default devices at their own sample rate and block size — a script that never mentions audio still makes sound and still records.

resonon setup is the Preferences dialog, in the terminal. It exists so that an interface is chosen from what this machine has rather than typed from memory — but what it produces is the same file you could write by hand, with your comments and key order kept. Neither door is the real one; the file is. Set Up This Machine shows both.

Device names are a fact about your machine: "Focusrite Scarlett 2i2" is true of one rig and meaningless on another. Channel numbers are a fact about your piece: drums.set_input(2, 3) means “the third and fourth inputs”, and that survives moving to a different rig. So channel routing stays in the music:

SettingCall
Master output channelsmaster >> Output(0, 1)
Per-track output channelsdrums >> Output(2, 3)
Per-track input channelsdrums.set_input(2, 3)

Three things, and they are the three things Live keeps as buttons rather than as fields:

CallWhat it does
plugin_scan()Rescan the plugin folders now.
plugin_rescan(path)Re-open one bundle, whatever the database says.
reload_preferences()Put the file in force.

resonon setup is a gesture too, and the same one Live’s Preferences dialog is: you open it, you change something, you close it. It writes the file; reload_preferences() is what puts a change in force in a session that is already playing.

They are actions — things you do at a moment — rather than settings, which are things that are true until you change them. That is the whole test.