Sound Byte Libs 29c5ff3
C++ firmware library for audio applications on 32-bit ARM Cortex-M processors
Loading...
Searching...
No Matches
Public Member Functions | List of all members
sbl::components::control::KnobGate Class Reference

#include <knob_gate.hpp>

Collaboration diagram for sbl::components::control::KnobGate:

Public Member Functions

 KnobGate (uint16_t threshold=2000)
 
void arm (uint16_t entry_value)
 Lock the gate and record current knob position.
 
void update (uint16_t current_value)
 Check if knob has moved enough from entry position to unlock.
 
bool live () const
 True when the gate is open (output allowed).
 
void force_live ()
 Force the gate open (e.g., for the initial mode that needs no gating).
 
void set_threshold (uint16_t t)
 Set threshold (0-65535).
 

Detailed Description

Definition at line 28 of file knob_gate.hpp.

Constructor & Destructor Documentation

◆ KnobGate()

sbl::components::control::KnobGate::KnobGate ( uint16_t  threshold = 2000)
inlineexplicit
Parameters
thresholdMovement required to unlock (0-65535). Default ~3%.

Definition at line 31 of file knob_gate.hpp.

Member Function Documentation

◆ arm()

void sbl::components::control::KnobGate::arm ( uint16_t  entry_value)
inline

Lock the gate and record current knob position.

Definition at line 35 of file knob_gate.hpp.

◆ force_live()

void sbl::components::control::KnobGate::force_live ( )
inline

Force the gate open (e.g., for the initial mode that needs no gating).

Definition at line 54 of file knob_gate.hpp.

◆ live()

bool sbl::components::control::KnobGate::live ( ) const
inline

True when the gate is open (output allowed).

Definition at line 51 of file knob_gate.hpp.

◆ set_threshold()

void sbl::components::control::KnobGate::set_threshold ( uint16_t  t)
inline

Set threshold (0-65535).

Definition at line 57 of file knob_gate.hpp.

◆ update()

void sbl::components::control::KnobGate::update ( uint16_t  current_value)
inline

Check if knob has moved enough from entry position to unlock.

Definition at line 41 of file knob_gate.hpp.


The documentation for this class was generated from the following file: