|
Sound Byte Libs 29c5ff3
C++ firmware library for audio applications on 32-bit ARM Cortex-M processors
|
Typedefs | |
| using | CvInput = sbl::components::cv::CvInput |
| using | CvInputConfig = sbl::components::cv::CvInputConfig |
| using | Smoothing = sbl::components::cv::Smoothing |
Functions | |
| template<typename Driver > | |
| uint16_t | read (CvInput &input, const AdcHandle &handle, adc::SampleTime sample_time=adc::SampleTime::Slow) |
| Read ADC channel and feed into CvInput filter. | |
| uint16_t | read_dma (CvInput &input, const uint16_t *buffer, uint8_t channel_index) |
| Read from DMA scan buffer and feed into CvInput filter. | |
| using sbl::cv::CvInput = typedef sbl::components::cv::CvInput |
| using sbl::cv::CvInputConfig = typedef sbl::components::cv::CvInputConfig |
| using sbl::cv::Smoothing = typedef sbl::components::cv::Smoothing |
|
inline |
Read ADC channel and feed into CvInput filter.
Blocking read followed by CvInput::update(). Returns the smoothed value.
| Driver | ADC driver type (e.g., sbl::driver::Adc) |
| input | CvInput instance to update |
| handle | ADC channel handle |
| sample_time | Sampling duration (default: Slow for pot sources) |
Definition at line 42 of file input.hpp.
References sbl::components::cv::CvInput::update(), and sbl::components::cv::CvInput::value().
|
inline |
Read from DMA scan buffer and feed into CvInput filter.
For use with sbl::adc::start_scan(). The DMA buffer is the abstraction boundary — no driver template needed. Casts to volatile to ensure the compiler generates a real memory read (buffer is updated by DMA hardware).
| input | CvInput instance to update |
| buffer | DMA scan buffer (from start_scan) |
| channel_index | Index of this channel in the scan sequence |
Definition at line 63 of file input.hpp.
References sbl::components::cv::CvInput::update(), and sbl::components::cv::CvInput::value().