ADISense1000 Version 2.1 code base

Fork of AdiSense1000_V21 by Sean Wilson

Committer:
kevin1990
Date:
Tue Dec 05 19:08:53 2017 +0000
Revision:
16:e4f2689363bb
v1.0_RC2 Release

Who changed what in which revision?

UserRevisionLine numberNew contents of line
kevin1990 16:e4f2689363bb 1 #ifndef __UTILS_H__
kevin1990 16:e4f2689363bb 2 #define __UTILS_H__
kevin1990 16:e4f2689363bb 3
kevin1990 16:e4f2689363bb 4 #include "inc/adi_sense_api.h"
kevin1990 16:e4f2689363bb 5 #include "inc/adi_sense_1000/adi_sense_1000_api.h"
kevin1990 16:e4f2689363bb 6
kevin1990 16:e4f2689363bb 7 #ifdef __cplusplus
kevin1990 16:e4f2689363bb 8 extern "C" {
kevin1990 16:e4f2689363bb 9 #endif
kevin1990 16:e4f2689363bb 10
kevin1990 16:e4f2689363bb 11 /* Utility function to print the status read from the ADI Sense device */
kevin1990 16:e4f2689363bb 12 void utils_printStatus(
kevin1990 16:e4f2689363bb 13 ADI_SENSE_STATUS *pStatus);
kevin1990 16:e4f2689363bb 14
kevin1990 16:e4f2689363bb 15 /* Utility function to print data samples read from the ADI Sense device */
kevin1990 16:e4f2689363bb 16 void utils_printSamples(
kevin1990 16:e4f2689363bb 17 ADI_SENSE_DATA_SAMPLE *pSampleBuffer,
kevin1990 16:e4f2689363bb 18 uint32_t numSamples);
kevin1990 16:e4f2689363bb 19
kevin1990 16:e4f2689363bb 20 /* Utility function to register callbacks for ADI Sense device notification signals */
kevin1990 16:e4f2689363bb 21 ADI_SENSE_RESULT utils_registerCallbacks(
kevin1990 16:e4f2689363bb 22 ADI_SENSE_DEVICE_HANDLE hDevice,
kevin1990 16:e4f2689363bb 23 volatile bool_t *pbDataReady,
kevin1990 16:e4f2689363bb 24 volatile bool_t *pbError,
kevin1990 16:e4f2689363bb 25 volatile bool_t *pbAlert);
kevin1990 16:e4f2689363bb 26
kevin1990 16:e4f2689363bb 27 /* Utility function to de-register callbacks for ADI Sense device notification signals */
kevin1990 16:e4f2689363bb 28 ADI_SENSE_RESULT utils_deregisterCallbacks(
kevin1990 16:e4f2689363bb 29 ADI_SENSE_DEVICE_HANDLE hDevice);
kevin1990 16:e4f2689363bb 30
kevin1990 16:e4f2689363bb 31 /* Utility function to run measurements on ADI Sense device, according to its current
kevin1990 16:e4f2689363bb 32 * configuration, and display data samples and device status following each cycle */
kevin1990 16:e4f2689363bb 33 ADI_SENSE_RESULT utils_runMeasurement(
kevin1990 16:e4f2689363bb 34 ADI_SENSE_DEVICE_HANDLE hDevice,
kevin1990 16:e4f2689363bb 35 ADI_SENSE_MEASUREMENT_MODE eMeasurementMode);
kevin1990 16:e4f2689363bb 36
kevin1990 16:e4f2689363bb 37 #ifdef __cplusplus
kevin1990 16:e4f2689363bb 38 }
kevin1990 16:e4f2689363bb 39 #endif
kevin1990 16:e4f2689363bb 40
kevin1990 16:e4f2689363bb 41 #endif /* __UTILS_H__ */
kevin1990 16:e4f2689363bb 42