182 #ifndef ti_drivers_ADC__include 183 #define ti_drivers_ADC__include 187 #include <ti/drivers/dpl/SemaphoreP.h> 197 #define ADC_convertRawToMicroVolts ADC_convertToMicroVolts 217 #define ADC_CMD_RESERVED (32) 232 #define ADC_STATUS_RESERVED (-32) 242 #define ADC_STATUS_SUCCESS (0) 250 #define ADC_STATUS_ERROR (-1) 259 #define ADC_STATUS_UNDEFINEDCMD (-2) 308 typedef void (*ADC_CloseFxn)(ADC_Handle handle);
315 typedef int_fast16_t (*ADC_ControlFxn)(ADC_Handle handle, uint_fast16_t cmd,
void *arg);
322 typedef int_fast16_t (*ADC_ConvertFxn)(ADC_Handle handle, uint16_t *value);
329 typedef int_fast16_t (*ADC_ConvertChainFxn)(ADC_Handle *handleList, uint16_t *dataBuffer, uint8_t channelCount);
336 typedef uint32_t (*ADC_ConvertToMicroVoltsFxn)(ADC_Handle handle, uint16_t adcValue);
343 typedef void (*ADC_InitFxn)(ADC_Handle handle);
360 ADC_CloseFxn closeFxn;
363 ADC_ControlFxn controlFxn;
366 ADC_ConvertFxn convertFxn;
369 ADC_ConvertChainFxn convertChainFxn;
372 ADC_ConvertToMicroVoltsFxn convertToMicroVolts;
412 extern void ADC_close(ADC_Handle handle);
435 extern int_fast16_t
ADC_control(ADC_Handle handle, uint_fast16_t cmd,
void *arg);
454 extern int_fast16_t
ADC_convert(ADC_Handle handle, uint16_t *value);
476 extern int_fast16_t
ADC_convertChain(ADC_Handle *handleList, uint16_t *dataBuffer, uint8_t channelCount);
ADC driver's custom configuration structure.
Definition: ADC.h:391
ADC_Handle ADC_open(uint_least8_t index, ADC_Params *params)
Function to initialize the ADC peripheral.
ADC Parameters used with ADC_open().
Definition: ADC.h:289
struct ADC_Config_ ADC_Config
ADC driver's custom configuration structure.
struct ADC_Config_ * ADC_Handle
A handle that is returned from an ADC_open() call.
Definition: ADC.h:279
ADC_FxnTable const * fxnTablePtr
Definition: ADC.h:395
uint32_t ADC_convertToMicroVolts(ADC_Handle handle, uint16_t adcValue)
Function to convert a raw ADC sample into microvolts.
const ADC_FxnTable ADCMSPM0_fxnTable
int_fast16_t ADC_convertChain(ADC_Handle *handleList, uint16_t *dataBuffer, uint8_t channelCount)
Function to perform a multi-channel ADC conversion.
void const * hwAttrs
Definition: ADC.h:402
The definition of an ADC function table that contains the required set of functions to control a spec...
Definition: ADC.h:357
void * object
Definition: ADC.h:398
void ADC_close(ADC_Handle handle)
Function to close an ADC driver instance.
int_fast16_t ADC_convert(ADC_Handle handle, uint16_t *value)
Function to perform an ADC conversion.
void ADC_init(void)
Function to initialize the ADC driver.
void ADC_Params_init(ADC_Params *params)
Initialize an ADC_Params structure to its default values.
bool isProtected
Definition: ADC.h:293
int_fast16_t ADC_control(ADC_Handle handle, uint_fast16_t cmd, void *arg)
Function performs implementation specific features on a driver instance.
void * custom
Definition: ADC.h:291