nRF Machine Learning: API documentation

Following are the API elements used by the application.

Edge Impulse Data Forwarder Event

Header file: applications/machine_learning/src/events/ei_data_forwarder_event.h
Source file: applications/machine_learning/src/events/ei_data_forwarder_event.c
group ei_data_forwarder_event

Edge Impulse Data Forwarder Event.

Enums

enum ei_data_forwarder_state

Edge Impulse data forwarder states.

Values:

enumerator EI_DATA_FORWARDER_STATE_DISABLED
enumerator EI_DATA_FORWARDER_STATE_DISCONNECTED
enumerator EI_DATA_FORWARDER_STATE_CONNECTED
enumerator EI_DATA_FORWARDER_STATE_TRANSMITTING
enumerator EI_DATA_FORWARDER_STATE_COUNT
struct ei_data_forwarder_event
#include <ei_data_forwarder_event.h>

Edge Impulse data forwarder event.

Public Members

struct app_event_header header

Event header.

enum ei_data_forwarder_state state

Edge Impulse data forwarder state.

Machine Learning Application Mode Event

Header file: applications/machine_learning/src/events/ml_app_mode_event.h
Source file: applications/machine_learning/src/events/ml_app_mode_event.c
group ml_app_mode_event

Machine Learning Application Mode Event.

Enums

enum ml_app_mode

Machine learning application modes.

Values:

enumerator ML_APP_MODE_MODEL_RUNNING
enumerator ML_APP_MODE_DATA_FORWARDING
enumerator ML_APP_MODE_COUNT
struct ml_app_mode_event
#include <ml_app_mode_event.h>

Machine learning application mode event.

Public Members

struct app_event_header header

Event header.

enum ml_app_mode mode

Machine learning application mode.

Machine Learning Result Event

Header file: applications/machine_learning/src/events/ml_result_event.h
Source file: applications/machine_learning/src/events/ml_result_event.c
group ml_result_event

Machine Learning Result Event.

struct ml_result_event
#include <ml_result_event.h>

Machine learning classification result event.

Public Members

struct app_event_header header

Event header.

const char *label

Classification label.

float value

Classification value.

float anomaly

Anomaly value.

Sensor Simulator Event

Header file: applications/machine_learning/src/events/sensor_sim_event.h
Source file: applications/machine_learning/src/events/sensor_sim_event.c
group sensor_sim_event

Simulated Sensor Event.

struct sensor_sim_event
#include <sensor_sim_event.h>

Simulated sensor event.

Public Members

struct app_event_header header

Event header.

const char *label

Label of generated signal.