MetaWear C++ API
0.18.0
C++ implementation of the MetaWear protocol
|
Detects and quantifies a pulse over the input values. More...
#include "processor_common.h"
Go to the source code of this file.
Enumerations | |
enum | MblMwPulseOutput { MBL_MW_PULSE_OUTPUT_WIDTH = 0, MBL_MW_PULSE_OUTPUT_AREA, MBL_MW_PULSE_OUTPUT_PEAK, MBL_MW_PULSE_OUTPUT_ON_DETECTION } |
Output modes for the processor. More... | |
Functions | |
METAWEAR_API int32_t | mbl_mw_dataprocessor_pulse_create (MblMwDataSignal *source, MblMwPulseOutput output, float threshold, uint16_t width, void *context, MblMwFnDataProcessor processor_created) |
Create a pulse detector. More... | |
METAWEAR_API int32_t | mbl_mw_dataprocessor_pulse_modify (MblMwDataProcessor *pulse, float threshold, uint16_t width) |
Modify the configuration of a pulse detector. More... | |
Detects and quantifies a pulse over the input values.
enum MblMwPulseOutput |
Output modes for the processor.
METAWEAR_API int32_t mbl_mw_dataprocessor_pulse_create | ( | MblMwDataSignal * | source, |
MblMwPulseOutput | output, | ||
float | threshold, | ||
uint16_t | width, | ||
void * | context, | ||
MblMwFnDataProcessor | processor_created | ||
) |
Create a pulse detector.
A pointer representing the processor will be passed back to the user via a callback function.
source | Data signal providing the input for the processor |
output | Output type of the processor |
threshold | Value the data must exceed for a valid pulse |
width | Number of samples that must exceed the threshold for a valid pulse |
context | Pointer to additional data for the callback function |
processor_created | Callback function to be executed when the processor is created |
METAWEAR_API int32_t mbl_mw_dataprocessor_pulse_modify | ( | MblMwDataProcessor * | pulse, |
float | threshold, | ||
uint16_t | width | ||
) |
Modify the configuration of a pulse detector.
pulse | Pulse detector to modify |
threshold | New threshold of the detector |
width | New width of the detector |