MetaWear C++ API  0.20.0
C++ implementation of the MetaWear protocol
pulse.h
Go to the documentation of this file.
1 
6 #pragma once
7 
8 #include "processor_common.h"
9 
10 #ifdef __cplusplus
11 extern "C" {
12 #endif
13 
17 typedef enum {
23 
36  float threshold, uint16_t width, void *context, MblMwFnDataProcessor processor_created);
45 METAWEAR_API int32_t mbl_mw_dataprocessor_pulse_modify(MblMwDataProcessor *pulse, float threshold, uint16_t width);
46 
47 #ifdef __cplusplus
48 }
49 #endif
void(* MblMwFnDataProcessor)(void *context, MblMwDataProcessor *processor)
Definition for callback functions that accept an MblMwDataProcessor pointer.
Definition: dataprocessor_fwd.h:23
struct MblMwDataProcessor MblMwDataProcessor
Data signal from the on board data processor.
Definition: dataprocessor_fwd.h:15
struct MblMwDataSignal MblMwDataSignal
A event fired from the MetaWear board that also contains data.
Definition: datasignal_fwd.h:15
#define METAWEAR_API
Indicates the function should be exported to the symbol table
Definition: dllmarker.h:27
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.
MblMwPulseOutput
Output modes for the processor.
Definition: pulse.h:17
@ MBL_MW_PULSE_OUTPUT_PEAK
Return the highest value in the pulse.
Definition: pulse.h:20
@ MBL_MW_PULSE_OUTPUT_AREA
Return a sum of all data points in the pulse.
Definition: pulse.h:19
@ MBL_MW_PULSE_OUTPUT_ON_DETECTION
Return a 0x01 as soon as a pulse is detected.
Definition: pulse.h:21
@ MBL_MW_PULSE_OUTPUT_WIDTH
Return number of samples in the pulse.
Definition: pulse.h:18
METAWEAR_API int32_t mbl_mw_dataprocessor_pulse_modify(MblMwDataProcessor *pulse, float threshold, uint16_t width)
Modify the configuration of a pulse detector.