MCUXpresso SDK API Reference Manual  Rev. 0
NXP Semiconductors
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages

Overview

Macros

#define I2C_RETRY_TIMES   0U /* Define to zero means keep waiting until the flag is assert/deassert. */
 Retry times for waiting flag. More...
 
#define I2C_COMMONCODE_ERROR   (0x00U)
 MASTER/SLAVE: Bus error happens. More...
 

Enumerations

enum  _i2c_status {
  kStatus_I2C_Busy = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 0),
  kStatus_I2C_Nak = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 1),
  kStatus_I2C_Addr_Nak = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 2),
  kStatus_I2C_BusError = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 3),
  kStatus_I2C_ArbitrationLost = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 4),
  kStatus_I2C_Timeout = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 5),
  kStatus_I2C_StateError = MAKE_STATUS(kStatusGroup_LPC_I2C_1, 6)
}
 I2C status return codes. More...
 
enum  _i2c_flags {
  kI2C_InterruptFlag = I2C0_CONCLR_SIC_MASK,
  kI2C_AssertACKFlag = I2C0_CONSET_AA_MASK,
  kI2C_StartFlag = I2C0_CONSET_STA_MASK,
  kI2C_StopFlag = I2C0_CONSET_STO_MASK,
  kI2C_AllFlags
}
 I2C peripheral flags. More...
 

Driver version

#define FSL_I2C_DRIVER_VERSION   (MAKE_VERSION(2, 0, 1))
 I2C driver version 2.0.1. More...
 

Macro Definition Documentation

#define FSL_I2C_DRIVER_VERSION   (MAKE_VERSION(2, 0, 1))
#define I2C_RETRY_TIMES   0U /* Define to zero means keep waiting until the flag is assert/deassert. */
#define I2C_COMMONCODE_ERROR   (0x00U)

Enumeration Type Documentation

Enumerator
kStatus_I2C_Busy 

The master is already performing a transfer.

kStatus_I2C_Nak 

The slave device sent a NAK in response to a byte.

kStatus_I2C_Addr_Nak 

NAK received during the address probe.

kStatus_I2C_BusError 

Transferred bit was not seen on the bus.

kStatus_I2C_ArbitrationLost 

Arbitration lost error.

kStatus_I2C_Timeout 

Timeout polling status flags.

kStatus_I2C_StateError 

Polling state error.

enum _i2c_flags

The following status register flags can be set/cleared:

Note
These enums are meant to be OR'd together to form a bit mask.
Enumerator
kI2C_InterruptFlag 

Clear to continue I2C state change.

kI2C_AssertACKFlag 

Set/Clear to issue an ACK/NACK.

kI2C_StartFlag 

Set/Clear to issue/clear START signal.

kI2C_StopFlag 

Set to issue STOP signal.

kI2C_AllFlags 

All CON flags.