Functions
I2CSupport.h File Reference

Detailed Description

Holder of common helper functions for the I2C driver.

============================================================================


#include <stddef.h>
#include <stdint.h>
#include <stdbool.h>
#include <ti/drivers/I2C.h>
Include dependency graph for I2CSupport.h:

Go to the source code of this file.

Functions

void I2CSupport_controllerFinish (I2C_HWAttrs const *hwAttrs)
 Function to send a finish command to the controller module. More...
 
void I2CSupport_powerSetConstraint (void)
 Function to set power constraint. More...
 
void I2CSupport_powerRelConstraint (void)
 Function to release power constraint. More...
 
int_fast16_t I2CSupport_primeTransfer (I2C_Handle handle, I2C_Transaction *transaction)
 Function to initialize transfers. More...
 

Function Documentation

§ I2CSupport_controllerFinish()

void I2CSupport_controllerFinish ( I2C_HWAttrs const *  hwAttrs)

Function to send a finish command to the controller module.

Parameters
[in]hwAttrsA pointer to an I2C_HWAttrs structure

§ I2CSupport_powerSetConstraint()

void I2CSupport_powerSetConstraint ( void  )

Function to set power constraint.

§ I2CSupport_powerRelConstraint()

void I2CSupport_powerRelConstraint ( void  )

Function to release power constraint.

§ I2CSupport_primeTransfer()

int_fast16_t I2CSupport_primeTransfer ( I2C_Handle  handle,
I2C_Transaction transaction 
)

Function to initialize transfers.

Parameters
[in]handleAn I2C_Handle returned from I2C_open()
[in]transactionA pointer to an I2C_Transaction
Returns
Returns a status indicating success or failure of the transfer
Return values
I2C_STATUS_SUCCESSThe transfer was successful
I2C_STATUS_INCOMPLETEI2C transaction is in progress or returned without completing
I2C_STATUS_BUS_BUSYI2C bus already in use by another I2C Controller
© Copyright 1995-2023, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale