distributor

quad voltage distributor The "amount" can be distributed over an x-axis and y-axis, while the y-axis can have it's own distribution-scaling for the x-axis for low-Y and high-Y.
Author: Remco van der Most
License: BSD
Github: sss/ctrl/distributor.axo

Inlets

None

Outlets

frac32 1

frac32 2

frac32 3

frac32 4

Parameters

frac32.u.map.gain amt

frac32.s.map x

frac32.s.map y12

frac32.s.map y34

Declaration
int32_t v27 = 1 << 27;
Control Rate
int32_t x = param_x + v27;
int32_t y12 = param_y12 + v27;
int32_t y34 = param_y34 + v27;
int32_t amt = param_amt >> 4;

int32_t a;
int32_t b;
int32_t c;
int32_t d;
a = amt - ___SMMUL(x, param_amt);
c = amt - a;
b = ___SMMUL(a, y12) << 4;
d = ___SMMUL(c, y34) << 4;
a -= b;
c -= d;
outlet_1 = __USAT(a << 2, 27);
outlet_2 = __USAT(b << 2, 27);
outlet_3 = __USAT(c << 2, 27);
outlet_4 = __USAT(d << 2, 27);

Privacy

© 2024 Zrna Research