19 #include <adi_processor.h> 20 #include <rtos_map/adi_rtos_map.h> 32 #if defined (__ICCARM__) 40 #pragma diag_suppress=Pm011 104 #define ADI_I2C_MEMORY_SIZE (48u + ADI_SEM_SIZE) 180 #define ADI_I2C_MAX_RATE (400000u) 207 #if defined (__ICCARM__) 208 #pragma diag_default=Pm011
ADI_I2C_RESULT adi_i2c_IssueGeneralCall(ADI_I2C_HANDLE const hDevice, uint8_t *const pData, uint8_t const nDataSize, uint32_t *const pHwErrors)
Transmit a General Call command to all slave devices on the I2C bus.
ADI_I2C_RESULT adi_i2c_Open(uint32_t const DeviceNum, void *const pMemory, uint32_t const MemorySize, ADI_I2C_HANDLE *const phDevice)
Initialize and allocate an I2C device for use in Master Mode.
ADI_I2C_RESULT adi_i2c_ReadWrite(ADI_I2C_HANDLE const hDevice, ADI_I2C_TRANSACTION *const pTransaction, uint32_t *const pHwErrors)
Blocking I2C Master-Mode data read/write API.
ADI_I2C_RESULT adi_i2c_IsBufferAvailable(ADI_I2C_HANDLE const hDevice, bool *const pbCompletionState)
Query if a non-blocking I2C transfer is complete.
ADI_I2C_RESULT adi_i2c_SetBusClear(ADI_I2C_HANDLE const hDevice, const bool busClr, const bool stopBusClr)
Assign BUSCLR and STOPBUSCLR bit values.
ADI_I2C_RESULT adi_i2c_GetHWMaskedErrors(ADI_I2C_HANDLE const hDevice, uint16_t *pHwMaskedErrors)
Get the errors that have been masked out.
struct __ADI_I2C_DEV_DATA_TYPE * ADI_I2C_HANDLE
ADI_I2C_RESULT adi_i2c_SetBitRate(ADI_I2C_HANDLE const hDevice, uint32_t const requestedBitRate32)
Set the I2C serial bus speed.
ADI_I2C_RESULT adi_i2c_Reset(ADI_I2C_HANDLE const hDevice)
Reset an I2C device and driver instance.
ADI_I2C_RESULT adi_i2c_GetNumberOfDataProcessed(ADI_I2C_HANDLE const hDevice, uint32_t *pDataCount)
Get the number of data written into MTX or read from MRX following the transmission/reception of a tr...
ADI_I2C_RESULT adi_i2c_SetHWMaskedErrors(ADI_I2C_HANDLE const hDevice, ADI_I2C_HW_ERRORS eMaskedErrors)
Mask out errors. Errors will not be reported.
ADI_I2C_RESULT adi_i2c_SetSlaveAddress(ADI_I2C_HANDLE const hDevice, uint16_t const SlaveAddress)
Set the I2C serial bus slave address.
ADI_I2C_RESULT adi_i2c_SubmitBuffer(ADI_I2C_HANDLE const hDevice, ADI_I2C_TRANSACTION *const pTransaction)
Non-Blocking I2C Master-Mode data read or data write API.
ADI_I2C_RESULT adi_i2c_Close(ADI_I2C_HANDLE const hDevice)
Uninitialize and deallocate an I2C device.
ADI_I2C_RESULT adi_i2c_GetBuffer(ADI_I2C_HANDLE const hDevice, uint32_t *const pHwErrors)
Request ownership of a submitted buffer.