SuperCollider On Organelle


#1

time for Supercollider on the Organelle :slight_smile:

Prerequisites

OS 3.0
Installer: https://patchstorage.com/supercollider-installer-sc_install/

copy zop file to Patches directory

you will then be offered the option
Install SC_Install.zip
click on this to install, and it will restart

after install you wont see anything… but if you download the SC examples (see below), you will be able to launch them , just like any other patch

Current features

OS 3.0 provides the abilty to launch supercollider patch and also the mother patch, you can override mother.scd by placing in either patch directory, or system directory

Mother patch, like pure data, for supercollider we have a mother patch (mother.scd) , which provides the interface to the Organelle hardware including Keys, Knobs, Screens, Master Volume, Vu-meters.

Usage

after installation, users simply need to put ‘SC patches’ into the Patches directory in the same way as they do for pure data patches.

Status

Its working … at least for me :wink:
Mother.scd provide features that are most likely needed, and will be continued to be extended.
however, during these early days, it is likely to change quite radically, as we learn how we want to interface the organelle efficiently with SC. so your patches may need to be updated to reflect these changes.

Test patch

a sample test patch, which shows how to create a patch, and also interact with Organelle is here:
https://patchstorage.com/simple-poly-on-supercollider/

Simply download this, and place into your ‘Patches’ directory.

I briefly explained this patch in this post.


Change logs

SC_Install

v0.1 Initial alpha release
v1.0 - 4/Dec/17 - fixed bugs
v1.1 - 11/Dec/17 - new installer zip , using OS 2.2 TB18
v1.2 - 18/Dec/17- new ZOP install for OS 3.0

Mother.scd

TB17 - 4/Dec/17 - initial release, support for oled,notes,knobs, footswitch, expression pedal, encoder
TB18 - 11/Dec/17 - fix issue with synths not die’ing due to OSC timing, mother.scd can be overriden
OS3.0 - 18/Dec/18 - includes mother.scd


Thanks for @emp for the pointers on this thread for getting it compiled.

This is really a pre-release of sorts, because it just installs supercollider , I will be following this up with support for running supercollider patches etc. But I thought useful to share for those that are already ‘in to’ supercollider.


#2

Oooh this looks interesting. Does this open up yet another whole new world? :smiley:


#3

It certainly opens up a DX7 emulation claiming to be near exactly accurate. This could be really something! Nice one @thetechnobear


#4

dx7.zip (990.3 KB)

Ask and you shall receive, this plays one note but is a thorough DX7 emu

i have been coding in SC since SC2 and got into it after i took a class on “micro-sound” composition in grad school
the book was written by Curtis Roads
http://mitpress.mit.edu/books/microsound

big fun about to go down, thanks for the hard work @thetechnobear


#5

Milestone… !!! or leave no stone unturned :wink:


#6

This is cool! does it install supercollider ui too? or can it run headless?


#7

Ive built it for headless use… as you can always use sclang on a remote computer to edit etc.

Ive got a new build of mother host which can launch sc patches (and also shell scripts which are launching patches).
but hit an issue, which has already been reported on the supercollider repo…
https://github.com/supercollider/supercollider/issues/2655

basically i can start the scsynth ok, but sclang doesnt like to be launched from processes… I’m assuming some issue with no having std io… as yet I cant find a workaround, every thing i try, basically hits the same issue.


#8

Just when I thought I was starting to understand posts on this forum, a thread like this shows up! :joy:

Joking aside, this just demonstrates the genius that is the Organelle.


#9

i assume you installed boost, is there no pacman supercollider?


#10

https://aur.archlinux.org/packages/supercollider-with-plugins/
??


#11

boost is a compile time dependency not runtime.

I’m currently looking at the supercollider source to see if I can fix/patch it. as linked above, it’s a known bug.


#12

figured out a workaround, so I can now launch SC patches from the Organelle patch menu :slight_smile:
( @emp if your interested in what the issue was, and workaround feel free to pm me)

now to develop some demo SC patches, and generally figure out what I want SC patches to look like under Organelle, and any special settings that might be needed.

Once Ive done that I’ll be putting out a new TB OS beta (Tb16) which incorporates the new patch launching code.

@oweno, we might want to consider if to incorporate SC into the new firmware - I guess we might as well, just need to copy the contents of the SC installer into the upgrade , thoughts?
(if we don’t, then I’ll probably put some code in mother host, such that SC patches do not show up unless SC is installed)


#13

i would be interested, i am going to catch my research Organelle up hopefully today or tomorrow to i can parallel run some of these. I want to do a SC Gendy
Also i think it would be cool to have an patch that takes say stuff like SCTweets and uses them in patches for effects etc… We need a simple select .SCD and Evaluate Code function i assume so synths can be re-run easily. This is really cool.
I already have Csound&RTCmix working this would be the FLipple crown or functionality :slight_smile:


#14

found another issue with sclang going to 100% cpu, fortunately found a fix too … but will mean I’ll need to update the SC_Installer… but will probably wait until Ive done a bit more testing, and see if there are any other issues to be caught.

but good news is I can update the OLED display without issue, and have had some success in getting knob values from mother host :slight_smile:


#15

that’s encouraging

pp


#16

I had literally just googled “supercollider hardware”. On the day my Organelle arrived. Opened the forum and saw this. Auspicious.
Fantastic @thetechnobear, thanks.


#17

i just want to share lightly that i have AT least as many SC patches as pure data ones that i have created, saved and curated since around 1998, so the games will begin when everything is tested out

:slight_smile:


#18

Ok, Its very nearly ready… Im working on mother.scd (mother.pd equiv.) as we speak…

currently, my test polyphonic synth is working… with full organelle functionality :slight_smile:

Actually I quite like SC, as you’ll see below in my example, is really compact for coding things up.

things still left to do for mother.scd

  • aux key

  • encoder handling

  • expression pedal

  • volume knob, this will patches using an audio bus, rather than using bus 0 (similar to throw~ in PD)

  • vumeter display

  • midi
    possibly, similar default CC/note I/O like PD, not decided, as i dont really use this, and it can be patches

Im not planning on initially on multiple page menu, user patches can do that… so think of its a mother.pd (v1).

Im pretty new to SC, so if there are some SC gurus out there that want to help on developing the mother.scd please shout… there are some interesting ‘technical issues’ :slight_smile:

anyway, unfortunately other things to do today… so will be a few days before release , but its getting there !


Ok, so on to the test synth … and what it looks like…

code breakdown of main.scd

all in one file, called main.scd, in the Patches directory… like PD.

Initialisation

notice here how I send messages to the OLED.

~voices = Dictionary.new;
~cutoff = 5000.0;
~oled.screen(5,"Test Patch Loaded");
~oled.screen(1,format("Cutoff % Hz",~cutoff.asInteger));

knob handling

create a callback function for handling the knobs, and then register it for callbacks (addDependent).
you can see I also take the opportunity to update the display… and any playing voices.

~knobfunc = {
    arg func, msg, knob, value;
    if(knob==0, {
        ~cutoff = value.linexp(0,1,50,20000);
        ~oled.screen(1,format("Cutoff % Hz",~cutoff.asInteger));
        ~voices.values.do({  arg  v;  v.set(\cutoff,~cutoff);  }
        );
    });
};
~knobs.addDependant(~knobfunc);

key handling

create a callback function for handling the keys, and then register it for callbacks (addDependent).
simply here, I create a voice if necessary for the key, and turn it off on note-off

~keyfunc = {
    arg func, msg, key, vel;
    if(vel>0 , {
        if(~voices[key]!=nil,{~voices[key].set(\gate,0);});
        ~voices[key] = Synth.new(\testSynth,[
            \freq, (key+59).midicps,
            \cutoff, ~cutoff,
        ]
    );
    } , {
        if(~voices[key]!=nil,{~voices[key].set(\gate,0);});
        ~voices[key] = nil;
    };
    )
};
~keys.addDependant(~keyfunc);

a synth to play :slight_smile:

and then a simply synth that has a low pass filter, so I can demonstrate the knobs (via cutoff)

SynthDef(\testSynth,
    {
        arg freq=440,gate=1,cutoff=440;
        var sig,env,amp=0.3;
        sig = Saw.ar(freq);
        env = EnvGen.ar(Env.adsr(),gate,doneAction:2);
        sig = sig * env * amp;
        sig = LPF.ar(sig,cutoff.clip(10,24000));
        Out.ar(0,sig!2);
    }
).add;

#19

this is cool. I’m gonna hop on this today after i squash some bugs and get sketches organized
cheers~


#20

nothing really to ‘hop on’ yet as Ive not pushed everything needed…
as mentioned in the last post, theres still a few things I want to complete first, then Im going to need to release a new SC_Installer, new ‘firmware’ and also hopefully a small ‘surprise’ extra… oh and some commented demos so that users have an idea of how to use it all.

as always, its one thing having it working on my own organelles, and another to have it in a state where I’m happy to release it :slight_smile:

but it was a weeks since I talked about it, so wanted to give a small status update, and to say its not too far away now… (I’ll admit the OTC 1.2 update, did sidetrack me a little ;))