Test, please delete

Embed: (wiki syntax)

« Back to documentation index

adi_sense_api.h File Reference

adi_sense_api.h File Reference

: ADSNS1000 Host Library Application Programming Interface (API) ----------------------------------------------------------------------------- More...

Go to the source code of this file.

Data Structures

struct  ADI_SENSE_CONNECTION
struct  ADI_SENSE_STATUS
struct  ADI_SENSE_DATA_SAMPLE

Typedefs

typedef void * ADI_SENSE_DEVICE_HANDLE

Enumerations

enum  ADI_SENSE_CONNECTION_TYPE { ADI_SENSE_CONNECTION_TYPE_SPI = 1 }
enum  ADI_SENSE_DEVICE_STATUS_FLAGS {
  ADI_SENSE_DEVICE_STATUS_BUSY = (1 << 0), ADI_SENSE_DEVICE_STATUS_DATAREADY = (1 << 1), ADI_SENSE_DEVICE_STATUS_ERROR = (1 << 2), ADI_SENSE_DEVICE_STATUS_ALERT = (1 << 3),
  ADI_SENSE_DEVICE_STATUS_FIFO_ERROR = (1 << 4), ADI_SENSE_DEVICE_STATUS_CONFIG_ERROR = (1 << 5), ADI_SENSE_DEVICE_STATUS_LUT_ERROR = (1 << 6), ADI_SENSE_DEVICE_STATUS_EXT_FLASH_ERROR = (1 << 7)
}
enum  ADI_SENSE_DIAGNOSTICS_STATUS_FLAGS {
  ADI_SENSE_DIAGNOSTICS_STATUS_CHECKSUM_ERROR = (1 << 0), ADI_SENSE_DIAGNOSTICS_STATUS_COMMS_ERROR = (1 << 1), ADI_SENSE_DIAGNOSTICS_STATUS_SUPPLY_MONITOR_ERROR = (1 << 2), ADI_SENSE_DIAGNOSTICS_STATUS_SUPPLY_CAP_ERROR = (1 << 3),
  ADI_SENSE_DIAGNOSTICS_STATUS_CONVERSION_ERROR = (1 << 8), ADI_SENSE_DIAGNOSTICS_STATUS_CALIBRATION_ERROR = (1 << 9)
}
enum  ADI_SENSE_CHANNEL_ALERT_FLAGS {
  ADI_SENSE_CHANNEL_ALERT_TIMEOUT = (1 << 0), ADI_SENSE_CHANNEL_ALERT_UNDER_RANGE = (1 << 1), ADI_SENSE_CHANNEL_ALERT_OVER_RANGE = (1 << 2), ADI_SENSE_CHANNEL_ALERT_LOW_LIMIT = (1 << 3),
  ADI_SENSE_CHANNEL_ALERT_HIGH_LIMIT = (1 << 4), ADI_SENSE_CHANNEL_ALERT_SENSOR_OPEN = (1 << 5), ADI_SENSE_CHANNEL_ALERT_REF_DETECT = (1 << 6), ADI_SENSE_CHANNEL_ALERT_CONFIG_ERR = (1 << 7),
  ADI_SENSE_CHANNEL_ALERT_LUT_ERR = (1 << 8), ADI_SENSE_CHANNEL_ALERT_SENSOR_NOT_READY = (1 << 9), ADI_SENSE_CHANNEL_ALERT_COMP_NOT_READY = (1 << 10), ADI_SENSE_CHANNEL_ALERT_LUT_UNDER_RANGE = (1 << 13),
  ADI_SENSE_CHANNEL_ALERT_LUT_OVER_RANGE = (1 << 14)
}
enum  ADI_SENSE_MEASUREMENT_MODE { ADI_SENSE_MEASUREMENT_MODE_HEALTHCHECK = 1, ADI_SENSE_MEASUREMENT_MODE_NORMAL, ADI_SENSE_MEASUREMENT_MODE_OMIT_RAW, ADI_SENSE_MEASUREMENT_MODE_FFT }
enum  ADI_SENSE_USER_CONFIG_SLOT

Functions

ADI_SENSE_RESULT adi_sense_Open (unsigned const nDeviceIndex, ADI_SENSE_CONNECTION *const pConnectionInfo, ADI_SENSE_DEVICE_HANDLE *const phDevice)
 Open ADISENSE device handle and set up communication interface.
ADI_SENSE_RESULT adi_sense_Close (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Close ADISENSE device context and free resources.
ADI_SENSE_RESULT adi_sense_GetGpioState (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_GPIO_PIN const ePinId, bool_t *const pbAsserted)
 Get the current state of the specified GPIO input signal.
ADI_SENSE_RESULT adi_sense_RegisterGpioCallback (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_GPIO_PIN const ePinId, ADI_SENSE_GPIO_CALLBACK const callbackFunction, void *const pCallbackParam)
 Register an application-defined callback function for GPIO interrupts.
ADI_SENSE_RESULT adi_sense_Shutdown (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Trigger a shut down of the device.
ADI_SENSE_RESULT adi_sense_Reset (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Reset the ADISENSE device.
ADI_SENSE_RESULT adi_sense_GetDeviceReadyState (ADI_SENSE_DEVICE_HANDLE const hDevice, bool_t *const pbReady)
 Check if the device is ready, following power-up or a reset.
ADI_SENSE_RESULT adi_sense_GetProductID (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_PRODUCT_ID *const pProductId)
 Obtain the product ID from the device.
ADI_SENSE_RESULT adi_sense_SetConfig (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_CONFIG *const pConfig)
 Write full configuration settings to the device registers.
ADI_SENSE_RESULT adi_sense_ApplyConfigUpdates (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Apply the configuration settings currently stored in device registers.
ADI_SENSE_RESULT adi_sense_SaveConfig (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_USER_CONFIG_SLOT const eSlotId)
 Store the configuration settings to persistent memory on the device.
ADI_SENSE_RESULT adi_sense_RestoreConfig (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_USER_CONFIG_SLOT const eSlotId)
 Restore configuration settings from persistent memory on the device.
ADI_SENSE_RESULT adi_sense_EraseExternalFlash (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Erases the external flash memory.
ADI_SENSE_RESULT adi_sense_GetExternalFlashSampleCount (ADI_SENSE_DEVICE_HANDLE const hDevice, uint32_t *nSampleCount)
 Gets the number of samples stored in the external flash memory.
ADI_SENSE_RESULT adi_sense_GetExternalFlashData (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_DATA_SAMPLE *const pSamples, uint32_t const nIndex, uint32_t const nRequested, uint32_t *const pnReturned)
 Read measurement samples stored in the the external flash memory.
ADI_SENSE_RESULT adi_sense_SaveLutData (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Store the LUT data to persistent memory on the device.
ADI_SENSE_RESULT adi_sense_RestoreLutData (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Restore LUT data from persistent memory on the device.
ADI_SENSE_RESULT adi_sense_StartMeasurement (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_MEASUREMENT_MODE const eMeasurementMode)
 Start the measurement cycles on the device.
ADI_SENSE_RESULT adi_sense_StopMeasurement (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Stop the measurement cycles on the device.
ADI_SENSE_RESULT adi_sense_RunDiagnostics (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Run built-in diagnostic checks on the device.
ADI_SENSE_RESULT adi_sense_RunCalibration (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Run built-in calibration on the device.
ADI_SENSE_RESULT adi_sense_RunDigitalCalibration (ADI_SENSE_DEVICE_HANDLE const hDevice)
 Run built-in digital calibration on the device.
ADI_SENSE_RESULT adi_sense_GetStatus (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_STATUS *const pStatus)
 Read the current status from the device registers.
ADI_SENSE_RESULT adi_sense_GetData (ADI_SENSE_DEVICE_HANDLE const hDevice, ADI_SENSE_MEASUREMENT_MODE const eMeasurementMode, ADI_SENSE_DATA_SAMPLE *const pSamples, uint8_t const nBytesPerSample, uint32_t const nRequested, uint32_t *const pnReturned)
 Read measurement data samples from the device registers.
ADI_SENSE_RESULT adi_sense_GetCommandRunningState (ADI_SENSE_DEVICE_HANDLE hDevice, bool_t *pbCommandRunning)
 Check if a command is currently running on the device.

Detailed Description

: ADSNS1000 Host Library Application Programming Interface (API) -----------------------------------------------------------------------------

: ADISENSE Host Library Application Programming Interface (API) -----------------------------------------------------------------------------

Definition in file adi_sense_api.h.