Skip to content

Compiling Faust code for Bela

giuliomoro edited this page Aug 30, 2016 · 19 revisions

#Compiling Faust code for Bela

We currently have beta support for Faust on Bela. Sorry, we do not have much documentation at the moment, but the below should be fine to get you started, whether or not you are familiar with Faust.

Go to http://faust.grame.fr/faustplayground and find some example patches in the BIBLIO and drop them on the playground, connect the audio output to preview in the browser, hit export->select Bela->exporter to build and then "telecharger" to download the compiled binary. Alternatively, you can use the online compiler http://faust.grame.fr/onlinecompiler, from where you can also download the Bela architecture file created by Oli Larkin and Stéphane Letz.

To interface Bela's analog and digital in, you need to click the edit button on a patch to edit it.

See the attached file as an example. You need to use the [BELA:ANALOG_0] or [BELA:DIGITAL_0] label , as in :

freq = hslider("[1]Frequency[BELA:ANALOG_0]", 440,460,1500,1):smooth(0.999);
pressure = hslider("[2]Pressure[style:knob][BELA:ANALOG_4]", 0.96, 0.2, 2.0, 0.01):smooth(0.999):min(0.99):max(0.2);
gate = hslider("[0]ON/OFF (ASR Envelope)[BELA:DIGITAL_0]",0,0,1,1);
Clone this wiki locally