![]() |
Documentation
Tools for embedded systems
|
A Tapped Delay Line (TDL) object. More...
#include <tdl.hpp>
Public Member Functions | |
virtual | ~tdl () |
tdl ()=default | |
tdl (real_t *const area, const size_t n, const real_t initVal=0.0_re) | |
Constructor for the Tapped Delay Line (TDL) instance. | |
template<size_t numberOfDelays> | |
tdl (real_t(&area)[numberOfDelays], const real_t initVal=0.0_re) noexcept | |
Constructor for the Tapped Delay Line (TDL) instance. | |
void | setup (real_t *const area, const size_t n, const real_t initVal=0.0_re) noexcept |
Setup and initialize a Tapped Delay Line (TDL) instance by setting the default optimal parameters. | |
template<size_t numberOfDelays> | |
void | setup (real_t(&area)[numberOfDelays], const real_t initVal=0.0_re) noexcept |
Setup and initialize a Tapped Delay Line (TDL) instance by setting the default optimal parameters. | |
void | flush (const real_t initVal=0.0_re) noexcept |
Clears all delays from the TDL and sets them to the specified value. | |
real_t | getOldest (void) const noexcept |
Get the oldest sample from the TDL x(k-n) | |
real_t | getRecent (void) const noexcept |
Get the most recent sample from the TDL x(k) | |
real_t | getAtIndex (const size_t i) const noexcept |
Get the specified delayed sample from the TDL x(k-i) | |
void | insertSample (const real_t sample) noexcept |
Insert a new sample to the TDL removing the oldest sample. | |
const real_t & | operator[] (int index) noexcept |
Get the specified delayed sample from the TDL x(k-i) | |
void | operator() (const real_t sample) noexcept |
Insert a new sample to the TDL removing the oldest sample. | |
bool | isInitialized (void) const |
Check if the TDL has been initialized. | |
A Tapped Delay Line (TDL) object.
The instance should be initialized using the td::setup() method.
|
inlinevirtual |
|
default |
Constructor for the Tapped Delay Line (TDL) instance.
[in] | area | An array of size n where delays will be stored |
[in] | n | The number of elements on area. |
[in] | initVal | The value with which all TDL delays will be initialized |
|
inlinenoexcept |
Constructor for the Tapped Delay Line (TDL) instance.
[in] | area | An array where delays will be stored |
[in] | initVal | The value with which all TDL delays will be initialized |
|
noexcept |
Clears all delays from the TDL and sets them to the specified value.
[in] | initVal | The value with which all TDL delays will be initialized |
|
noexcept |
Get the specified delayed sample from the TDL x(k-i)
[in] | i | The requested delay index |
|
noexcept |
Get the oldest sample from the TDL x(k-n)
|
noexcept |
Get the most recent sample from the TDL x(k)
|
noexcept |
Insert a new sample to the TDL removing the oldest sample.
[in] | sample | The new sample to insert. |
|
inline |
Check if the TDL has been initialized.
true
if instance has been initialized
|
inlinenoexcept |
Insert a new sample to the TDL removing the oldest sample.
[in] | sample | The new sample to insert. |
|
noexcept |
Get the specified delayed sample from the TDL x(k-i)
[in] | index | The requested delay index |
|
noexcept |
Setup and initialize a Tapped Delay Line (TDL) instance by setting the default optimal parameters.
[in] | area | An array of size n where delays will be stored |
[in] | n | The number of elements on area. |
[in] | initVal | The value with which all TDL delays will be initialized |
|
inlinenoexcept |
Setup and initialize a Tapped Delay Line (TDL) instance by setting the default optimal parameters.
[in] | area | The array where delays will be stored |
[in] | initVal | The value with which all TDL delays will be initialized |