Hi, finally I took the time to test the trill support in faust2bela. attached is the modified architecture file.
It works for now with the trill bar and square. it is easy to add ring and hex support .
Considering craft and flex, I think we have to approach things differently.
Currently it is theoretically possible to use simultaneously 8 bar and 8 square with for each of them the position and the pressure as values. unfortunately I could not test the limits having only 2 trill at my disposal (1 bar and 1 square).
the routing of i2c addresses is done in hard there are 2 tables in the code that allow to assign the addresses to the indexes :
const uint8_t TrillBarAdress[] = {0x20,0x21,0x22,0x23,0x24,0x25,0x26,0x27};
const uint8_t TrillSquareAdress[] = {0x28,0x29,0x2A,0x2B,0x2C,0x2D,0x2E,0x2F};
the keywords to be used in faust programs are of the type :
TRILL:BAR_POS_n, TRILL:BAR_LVL_n
TRILL:SQUARE_XPOS_n, TRILL:SQUARE_YPOS_n, TRILL:SQUARE_LVL_n,
here is a faust test program :
import("stdfaust.lib");
Freq = hslider("[0]Frequence[TRILL:BAR_POS_0]",220,50,2000,0.5):si.smoo;
Gate = hslider("[1]Gate[TRILL:BAR_LVL_0]",0,0,1,0.1):si.smoo;
Tremolo= hslider("[2]Tremolo[TRILL:SQUARE_XPOS_0]",0,0,0.2,0.01);
TremFreq=hslider("[3]TremFreq[TRILL:SQUARE_YPOS_0]",2,1,10,0.1);
Gate2 = hslider("[4]Gate2[BELA:ANALOG_0]",0.5,0,1,0.1):si.smoo;
FreqVar=1+os.osc(TremFreq)*Tremolo;
process = os.osc(Freq*FreqVar)*Gate*Gate2 <: _,_;