lfoSLAVE

This is the in/output module to be used with the "lfoCORE" module. This module uses the codes in the core module to calculate it's waveform. This way the seperate wave-codes only have to be written once into memory and can then be called upon by multiple lfoSLAVE instances. Don't forget to reference to the lfoCORE module!
Author: Remco van der Most
License: BSD
Github: sss/lfo/lfoSLAVE.axo

Inlets

frac32 rate

frac32 quantize

frac32 stepsize/multiplier

frac32 slope

frac32 phase-offset

bool32 sync input

int32 divides the rate in integer values. eg. useful with my morphing modules providing a "div" output. When not connected, is set to /1

int32 wave select

Outlets

bool32 snc-output (high single-pulse trigger)

frac32 waveform output

Parameters

frac32.u.map selects waveform

frac32.u.map sets quantification of the lfo (in powers of 2 division)

frac32.u.map.gain multiplies phase position-> changes steps when precision quantizes the signal, otherwise starts repeating waveform within single cycle

frac32.s.map.kpitch dampens the outgoing signal

bool32.tgl when on, lfo syncs to r-input

frac32.s.map sets rate based on host tempo (also connect lfoCORE module's HS-input!)

frac32.s.map offsets the mid-position of the phase, changing the waveshapes

Attributes

objref core

Declaration
int32_t LP1;
int32_t LP2;
int32_t lfo;
uint32_t P4;
bool rtrg;
bool TRG;
int32_t LFO(uint32_t phase, int32_t rst, int32_t snc, int32_t rate, int Div,
            int32_t slope, int wave, int32_t precision, int32_t step,
            int32_t damp) {
  int32_t dmp;
  MTOF(damp, dmp)
  dmp = dmp;
  attr_core.LFO(P4, phase << 5, rst, snc, rate, Div > 0 ? Div : 1, slope, wave,
                precision, step, rtrg);
  LP1 = ___SMMLA((((attr_core.out >> 1) + (1 << 26)) - LP1) << 1, dmp, LP1);
  LP2 = ___SMMLA((LP1 - LP2) << 1, dmp, LP2);
  lfo = LP2;
  TRG = attr_core.TRG;
  P4 = attr_core.PHS;
  rtrg = attr_core.rtrig;
}
Control Rate
LFO(inlet_phase, inlet_r, param_snc, param_rate + inlet_rate, inlet_div,
    param_slope + inlet_slope, (param_wave >> 23) + inlet_wave,
    param_precision + inlet_precision, param_step + inlet_step, param_damp);
outlet_snc = TRG;
outlet_w1 = lfo;

Privacy

© 2024 Zrna Research