ISF  2.2 rev 5
Intelligent Sensing Framework for Kinetis with Processor Expert
isf_sm_types.h File Reference

The isf_sm_types.h contains the collection of type definitions used in the Sensor Manager Interface as well as related defines and data structures required. More...

#include "isf.h"
#include "isf_sensor_types.h"
#include "isf_dsa_adapter.h"
Include dependency graph for isf_sm_types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  isf_SubscriptionSettings_t
 

Macros

#define SM_MAX_SUBSCRIBERS_PER_SENSOR   (3)
 This status code indicates that the API operation was successful. More...
 
#define SM_MAX_FIFO_DEPTH   (20)
 This is the maximum allowed depth of the sample FIFO. More...
 
#define SM_API_ERR_TOKEN_ID   (sm_result_t)(-1L)
 This is returned by the Sensor Manager when an invalid token ID is passed into any of the API calls. More...
 
#define SM_API_ERR_SENSOR_ID   (sm_result_t)(-2L)
 This is returned by the Sensor Manager when the passed parameter, sensor ID, does not match an existing sensor. More...
 
#define SM_API_ERR_ALREADY_BEGUN   (sm_result_t)(-3L)
 This is returned by the Sensor Manager when the sensor data flow is already enabled. More...
 
#define SM_API_ERR_NOT_YET_BEGUN   (sm_result_t)(-4L)
 This is returned by the Sensor Manager when the sensor data is unavailable because the data stream has not been started. More...
 
#define SM_API_ERR_SUBSCRIBER_COUNT   (sm_result_t)(-5L)
 This is returned by the Sensor Manager when the maximum number of subscribers as defined in SM_MAX_SUBSCRIBERS_PER_SENSOR for this particular sensor has been exceeded. More...
 
#define SM_API_ERR_NO_MEMORY   (sm_result_t)(-6L)
 This is returned by the Sensor Manager when an out-of- memory error status is returned during the execution of the API. More...
 
#define SM_API_ERR_FIFO_OVER_LIMIT   (sm_result_t)(-7L)
 This is returned by the Sensor Manager when the requested FIFO depth is larger than the FIFO limit specified in SM_MAX_FIFO_DEPTH. More...
 
#define SM_API_ERR_SAMPLE_TAP_RATE   (sm_result_t)(-8L)
 This is returned by the Sensor Manager when the requested sample tap rate is invalid. More...
 
#define SM_API_ERR_SETTINGS_TO_USE   (sm_result_t)(-9L)
 This is returned by the Sensor Manager when the requested sensor settings are invalid. More...
 
#define SM_API_ALTERNATE_OFFERED   (sm_result_t)(-10L)
 This is the status code returned by the Sensor Manager when the sensor cannot be configured based on user requested sensor settings. Additionally, the Sensor Manager provides a suggestion for the next best alternate rate and other possible settings. More...
 
#define SM_API_ERR_BUFFERLOCK_TIMEOUT   (sm_result_t)(-11L)
 This is returned by the Sensor Manager when the sample buffer lock call fails. More...
 
#define SM_API_ERR_LOCK_CREATION_FAILED   (sm_result_t)(-12L)
 This is returned by the Sensor Manager when the MQX semaphore create call fails. More...
 
#define SM_API_ERR_SENSOR_NOT_AVAIL   (sm_result_t)(-21L)
 This is returned by the Sensor Manager when the requested sensor is not available. More...
 
#define SM_API_ERR_SENSOR_ALREADY_INITIALIZED   (sm_result_t)(-22L)
 This is returned by the Sensor Manager when the sensor is already initialized. More...
 
#define SM_API_ERR_SENSOR_INIT_FAILED   (sm_result_t)(-23L)
 This is returned by the Sensor Manager when the sensor initialization was not successful. More...
 
#define SM_API_ERR_INVALID_HANDLE   (sm_result_t)(-24L)
 This is returned by the Sensor Manager when it receives an invalid handle. More...
 
#define SM_API_ERR_INVALID_PTR   (sm_result_t)(-25L)
 This is returned by the Sensor Manager when it receives an invalid pointer. More...
 
#define SM_API_ERR_MAX_TAPS_PER_SENSOR   (sm_result_t)(-26L)
 This is returned by the Sensor Manager when no more sensor taps are available. More...
 
#define SM_API_ERR_DATATYPE_NOT_SUPPORTED   (sm_result_t)(-27L)
 This is returned by the Sensor Manager when no more sensor taps are available. More...
 

Typedefs

typedef int32 sm_result_t
 Sensor Manager API return type. More...
 
typedef uint32 sm_token_t
 Sensor Manager subscription token type. More...
 
typedef enum SubscriptionSettingChoices SubscriptionSettingsChoices_t
 

Enumerations

enum  SubscriptionSettingChoices { SM_CURRENT_SETTINGS = 1, SM_GIVEN_SETTINGS, SM_BEST_POSSIBLE_SETTINGS }
 

Detailed Description

The isf_sm_types.h contains the collection of type definitions used in the Sensor Manager Interface as well as related defines and data structures required.

Definition in file isf_sm_types.h.

Macro Definition Documentation

#define SM_API_ALTERNATE_OFFERED   (sm_result_t)(-10L)

This is the status code returned by the Sensor Manager when the sensor cannot be configured based on user requested sensor settings. Additionally, the Sensor Manager provides a suggestion for the next best alternate rate and other possible settings.

Definition at line 115 of file isf_sm_types.h.

#define SM_API_ERR_ALREADY_BEGUN   (sm_result_t)(-3L)

This is returned by the Sensor Manager when the sensor data flow is already enabled.

Definition at line 65 of file isf_sm_types.h.

#define SM_API_ERR_BUFFERLOCK_TIMEOUT   (sm_result_t)(-11L)

This is returned by the Sensor Manager when the sample buffer lock call fails.

Definition at line 120 of file isf_sm_types.h.

#define SM_API_ERR_DATATYPE_NOT_SUPPORTED   (sm_result_t)(-27L)

This is returned by the Sensor Manager when no more sensor taps are available.

Definition at line 163 of file isf_sm_types.h.

#define SM_API_ERR_FIFO_OVER_LIMIT   (sm_result_t)(-7L)

This is returned by the Sensor Manager when the requested FIFO depth is larger than the FIFO limit specified in SM_MAX_FIFO_DEPTH.

Definition at line 94 of file isf_sm_types.h.

#define SM_API_ERR_INVALID_HANDLE   (sm_result_t)(-24L)

This is returned by the Sensor Manager when it receives an invalid handle.

Definition at line 148 of file isf_sm_types.h.

#define SM_API_ERR_INVALID_PTR   (sm_result_t)(-25L)

This is returned by the Sensor Manager when it receives an invalid pointer.

Definition at line 153 of file isf_sm_types.h.

#define SM_API_ERR_LOCK_CREATION_FAILED   (sm_result_t)(-12L)

This is returned by the Sensor Manager when the MQX semaphore create call fails.

Definition at line 125 of file isf_sm_types.h.

#define SM_API_ERR_MAX_TAPS_PER_SENSOR   (sm_result_t)(-26L)

This is returned by the Sensor Manager when no more sensor taps are available.

Definition at line 158 of file isf_sm_types.h.

#define SM_API_ERR_NO_MEMORY   (sm_result_t)(-6L)

This is returned by the Sensor Manager when an out-of- memory error status is returned during the execution of the API.

Definition at line 87 of file isf_sm_types.h.

#define SM_API_ERR_NOT_YET_BEGUN   (sm_result_t)(-4L)

This is returned by the Sensor Manager when the sensor data is unavailable because the data stream has not been started.

Definition at line 72 of file isf_sm_types.h.

#define SM_API_ERR_SAMPLE_TAP_RATE   (sm_result_t)(-8L)

This is returned by the Sensor Manager when the requested sample tap rate is invalid.

Definition at line 100 of file isf_sm_types.h.

#define SM_API_ERR_SENSOR_ALREADY_INITIALIZED   (sm_result_t)(-22L)

This is returned by the Sensor Manager when the sensor is already initialized.

Definition at line 138 of file isf_sm_types.h.

#define SM_API_ERR_SENSOR_ID   (sm_result_t)(-2L)

This is returned by the Sensor Manager when the passed parameter, sensor ID, does not match an existing sensor.

Definition at line 60 of file isf_sm_types.h.

#define SM_API_ERR_SENSOR_INIT_FAILED   (sm_result_t)(-23L)

This is returned by the Sensor Manager when the sensor initialization was not successful.

Definition at line 143 of file isf_sm_types.h.

#define SM_API_ERR_SENSOR_NOT_AVAIL   (sm_result_t)(-21L)

This is returned by the Sensor Manager when the requested sensor is not available.

Definition at line 131 of file isf_sm_types.h.

#define SM_API_ERR_SETTINGS_TO_USE   (sm_result_t)(-9L)

This is returned by the Sensor Manager when the requested sensor settings are invalid.

Definition at line 106 of file isf_sm_types.h.

#define SM_API_ERR_SUBSCRIBER_COUNT   (sm_result_t)(-5L)

This is returned by the Sensor Manager when the maximum number of subscribers as defined in SM_MAX_SUBSCRIBERS_PER_SENSOR for this particular sensor has been exceeded.

Definition at line 80 of file isf_sm_types.h.

#define SM_API_ERR_TOKEN_ID   (sm_result_t)(-1L)

This is returned by the Sensor Manager when an invalid token ID is passed into any of the API calls.

Definition at line 54 of file isf_sm_types.h.

#define SM_MAX_FIFO_DEPTH   (20)

This is the maximum allowed depth of the sample FIFO.

Note: This define must not be changed by the user.

Definition at line 34 of file isf_sm_types.h.

#define SM_MAX_SUBSCRIBERS_PER_SENSOR   (3)

This status code indicates that the API operation was successful.

This is the maximum number of subscribers allowed per sensor.

Note: This define must not be changed by the user.

Definition at line 27 of file isf_sm_types.h.

Typedef Documentation

typedef int32 sm_result_t

Sensor Manager API return type.

Definition at line 37 of file isf_sm_types.h.

typedef uint32 sm_token_t

Sensor Manager subscription token type.

Definition at line 40 of file isf_sm_types.h.

Defines for subscriber setting options.

Enumeration Type Documentation

Defines for subscriber setting options.

Enumerator
SM_CURRENT_SETTINGS 

Use the current sensor settings.

SM_GIVEN_SETTINGS 

Use the user-provided sensor settings if possible.

SM_BEST_POSSIBLE_SETTINGS 

Use the given settings, if possible. If not, use the best possible settings.

Definition at line 166 of file isf_sm_types.h.