Data Structures | Macros | Typedefs | Functions
gr55xx_ll_i2c.h File Reference

Header file containing functions prototypes of I2C LL library. More...

`#include "gr55xx.h"`

Go to the source code of this file.

## Data Structures
struct | _ll_i2c_init
| LL I2C init Structure definition. More...

## Macros
#define | LL_I2C_INTR_STAT_MST_ON_HOLD I2C_INTR_GEN_CALL
#define | LL_I2C_INTR_STAT_RESTART_DET I2C_INTR_RESTART_DET
#define | LL_I2C_INTR_STAT_GEN_CALL I2C_INTR_GEN_CALL
#define | LL_I2C_INTR_STAT_START_DET I2C_INTR_START_DET
#define | LL_I2C_INTR_STAT_STOP_DET I2C_INTR_STOP_DET
#define | LL_I2C_INTR_STAT_ACTIVITY I2C_INTR_ACTIVITY
#define | LL_I2C_INTR_STAT_RX_DONE I2C_INTR_RX_DONE
#define | LL_I2C_INTR_STAT_TX_ABRT I2C_INTR_TX_ABRT
#define | LL_I2C_INTR_STAT_RD_REQ I2C_INTR_RD_REQ
#define | LL_I2C_INTR_STAT_TX_EMPTY I2C_INTR_TX_EMPTY
#define | LL_I2C_INTR_STAT_TX_OVER I2C_INTR_TX_OVER
#define | LL_I2C_INTR_STAT_RX_FULL I2C_INTR_RX_FULL
#define | LL_I2C_INTR_STAT_RX_OVER I2C_INTR_RX_OVER
#define | LL_I2C_INTR_STAT_RX_UNDER I2C_INTR_RX_UNDER
#define | LL_I2C_ABRT_TX_FLUSH_CNT I2C_TX_ABRT_SRC_TX_FLUSH_CNT
#define | LL_I2C_ABRT_USER_ABRT I2C_TX_ABRT_SRC_USER_ABRT
#define | LL_I2C_ABRT_SLVRD_INTX I2C_TX_ABRT_SRC_SLVRD_INTX
#define | LL_I2C_ABRT_SLV_ARBLOST I2C_TX_ABRT_SRC_SLV_ARBLOST
#define | LL_I2C_ABRT_SLVFLUSH_TXFIFO I2C_TX_ABRT_SRC_SLVFLUSH_TXFIFO
#define | LL_I2C_ABRT_ARB_LOST I2C_TX_ABRT_SRC_ARB_LOST
#define | LL_I2C_ABRT_MST_DIS I2C_TX_ABRT_SRC_MST_DIS
#define | LL_I2C_ABRT_10B_RD_NORSTRT I2C_TX_ABRT_SRC_10B_RD_NORSTRT
#define | LL_I2C_ABRT_SBYTE_NORSTRT I2C_TX_ABRT_SRC_SBYTE_NORSTRT
#define | LL_I2C_ABRT_HS_NORSTRT I2C_TX_ABRT_SRC_HS_NORSTRT
#define | LL_I2C_ABRT_SBYTE_ACKDET I2C_TX_ABRT_SRC_SBYTE_ACKDET
#define | LL_I2C_ABRT_HS_ACKDET I2C_TX_ABRT_SRC_HS_ACKDET
#define | LL_I2C_ABRT_GCALL_READ I2C_TX_ABRT_SRC_GCALL_READ
#define | LL_I2C_ABRT_GCALL_NOACK I2C_TX_ABRT_SRC_GCALL_NOACK
#define | LL_I2C_ABRT_TXDATA_NOACK I2C_TX_ABRT_SRC_TXDATA_NOACK
#define | LL_I2C_ABRT_10ADDR2_NOACK I2C_TX_ABRT_SRC_10ADDR2_NOACK
#define | LL_I2C_ABRT_10ADDR1_NOACK I2C_TX_ABRT_SRC_10ADDR1_NOACK
#define | LL_I2C_ABRT_7B_ADDR_NOACK I2C_TX_ABRT_SRC_7B_ADDR_NOACK
#define | LL_I2C_INTR_MASK_MST_ON_HOLD I2C_INTR_GEN_CALL
#define | LL_I2C_INTR_MASK_RESTART_DET I2C_INTR_RESTART_DET
#define | LL_I2C_INTR_MASK_GEN_CALL I2C_INTR_GEN_CALL
#define | LL_I2C_INTR_MASK_START_DET I2C_INTR_START_DET
#define | LL_I2C_INTR_MASK_STOP_DET I2C_INTR_STOP_DET
#define | LL_I2C_INTR_MASK_ACTIVITY I2C_INTR_ACTIVITY
#define | LL_I2C_INTR_MASK_RX_DONE I2C_INTR_RX_DONE
#define | LL_I2C_INTR_MASK_TX_ABRT I2C_INTR_TX_ABRT
#define | LL_I2C_INTR_MASK_RD_REQ I2C_INTR_RD_REQ
#define | LL_I2C_INTR_MASK_TX_EMPTY I2C_INTR_TX_EMPTY
#define | LL_I2C_INTR_MASK_TX_OVER I2C_INTR_TX_OVER
#define | LL_I2C_INTR_MASK_RX_FULL I2C_INTR_RX_FULL
#define | LL_I2C_INTR_MASK_RX_OVER I2C_INTR_RX_OVER
#define | LL_I2C_INTR_MASK_RX_UNDER I2C_INTR_RX_UNDER
#define | LL_I2C_INTR_MASK_ALL 0x00000FFFU
#define | LL_I2C_ADDRESSING_MODE_7BIT 0x00000000U
#define | LL_I2C_ADDRESSING_MODE_10BIT I2C_CON_10BITADDR_MST
#define | LL_I2C_OWNADDRESS_7BIT 0x00000000U
#define | LL_I2C_OWNADDRESS_10BIT I2C_CON_10BITADDR_SLV
#define | LL_I2C_CMD_SLV_NONE 0x00000000U
#define | LL_I2C_CMD_MST_WRITE 0x00000000U
#define | LL_I2C_CMD_MST_READ I2C_DATA_CMD_CMD
#define | LL_I2C_CMD_MST_GEN_STOP I2C_DATA_CMD_STOP
#define | LL_I2C_CMD_MST_GEN_RESTART I2C_DATA_CMD_RESTART
#define | LL_I2C_SPEED_MODE_STANDARD I2C_CON_SPEED_STANDARD
#define | LL_I2C_SPEED_MODE_FAST I2C_CON_SPEED_FAST
#define | LL_I2C_SPEED_MODE_HIGH I2C_CON_SPEED_HIGH
#define | LL_I2C_SPEED_100K (100000ul)
#define | LL_I2C_SPEED_400K (400000ul)
#define | LL_I2C_SPEED_1000K (1000000ul)
#define | LL_I2C_SPEED_2000K (2000000ul)
#define | LL_I2C_DIRECTION_NONE 0x00000000U
#define | LL_I2C_DIRECTION_WRITE I2C_INTR_RX_FULL
#define | LL_I2C_DIRECTION_READ I2C_INTR_RD_REQ
#define | LL_I2C_DIRECTION_ERROR I2C_INTR_RX_FULL | I2C_INTR_RD_REQ
#define | LL_I2C_TX_FIFO_TH_EMPTY 0x00000000U
#define | LL_I2C_TX_FIFO_TH_CHAR_1 0x00000001U
#define | LL_I2C_TX_FIFO_TH_CHAR_2 0x00000002U
#define | LL_I2C_TX_FIFO_TH_CHAR_3 0x00000003U
#define | LL_I2C_TX_FIFO_TH_CHAR_4 0x00000004U
#define | LL_I2C_TX_FIFO_TH_CHAR_5 0x00000005U
#define | LL_I2C_TX_FIFO_TH_CHAR_6 0x00000006U
#define | LL_I2C_TX_FIFO_TH_CHAR_7 0x00000007U
#define | LL_I2C_RX_FIFO_TH_CHAR_1 0x00000000U
#define | LL_I2C_RX_FIFO_TH_CHAR_2 0x00000001U
#define | LL_I2C_RX_FIFO_TH_CHAR_3 0x00000002U
#define | LL_I2C_RX_FIFO_TH_CHAR_4 0x00000003U
#define | LL_I2C_RX_FIFO_TH_CHAR_5 0x00000004U
#define | LL_I2C_RX_FIFO_TH_CHAR_6 0x00000005U
#define | LL_I2C_RX_FIFO_TH_CHAR_7 0x00000006U
#define | LL_I2C_RX_FIFO_TH_FULL 0x00000007U
#define | LL_I2C_DEFAULT_CONFIG
| LL I2C InitStrcut default configuartion. More...
#define | LL_I2C_WriteReg(__instance__, __REG__, __VALUE__) WRITE_REG(__instance__->__REG__, (__VALUE__))
| Write a value in I2C register. More...
#define | LL_I2C_ReadReg(__instance__, __REG__) READ_REG(__instance__->__REG__)
| Read a value in I2C register. More...
#define | __LL_I2C_CONVERT_CLK_SSL_CNT(__PERIPHCLK__, __SPEED__) ((__PERIPHCLK__) / 2 / (__SPEED__))
| Compute CLK_SSL_CNT value according to Peripheral Clock and expected Speed. More...
#define | __LL_I2C_CONVERT_SPEED_MODE(__SPEED__)
| Get Speed Mode according to expected Speed. More...

## Typedefs
typedef struct _ll_i2c_init | ll_i2c_init_t
| LL I2C init Structure definition.

## Functions
__STATIC_INLINE void | ll_i2c_enable (i2c_regs_t *I2Cx)
| Enable I2C peripheral (ENABLE = 1). More...
__STATIC_INLINE void | ll_i2c_disable (i2c_regs_t *I2Cx)
| Disable I2C peripheral (ENABLE = 0). More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled (i2c_regs_t *I2Cx)
| Check if the I2C peripheral is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_master_mode (i2c_regs_t *I2Cx)
| Enable I2C master mode. More...
__STATIC_INLINE void | ll_i2c_disable_master_mode (i2c_regs_t *I2Cx)
| Disable I2C master mode and enable slave mode. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_master_mode (i2c_regs_t *I2Cx)
| Check if I2C master mode is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_general_call (i2c_regs_t *I2Cx)
| Enable General Call(slave mode). More...
__STATIC_INLINE void | ll_i2c_disable_general_call (i2c_regs_t *I2Cx)
| Disable General Call(slave mode). More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_general_call (i2c_regs_t *I2Cx)
| Check if General Call is enabled or disabled(slave mode). More...
__STATIC_INLINE void | ll_i2c_enable_master_restart (i2c_regs_t *I2Cx)
| Enable Master Restart. More...
__STATIC_INLINE void | ll_i2c_disable_master_restart (i2c_regs_t *I2Cx)
| Disable Master Restart. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_master_restart (i2c_regs_t *I2Cx)
| Check if Master Restart is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_stop_det_if_addressed (i2c_regs_t *I2Cx)
| Enable Slave issues STOP_DET interrupt only if addressed function. More...
__STATIC_INLINE void | ll_i2c_disable_stop_det_if_addressed (i2c_regs_t *I2Cx)
| Disable Slave issues STOP_DET interrupt only if addressed function. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_stop_det_if_addressed (i2c_regs_t *I2Cx)
| Check if Slave issues STOP_DET interrupt only if addressed function is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_set_master_addressing_mode (i2c_regs_t *I2Cx, uint32_t addressing_mode)
| Configure the Master to transfers in 7-bit or 10-bit addressing mode. More...
__STATIC_INLINE uint32_t | ll_i2c_get_master_addressing_mode (i2c_regs_t *I2Cx)
| Get the Master addressing mode. More...
__STATIC_INLINE void | ll_i2c_set_own_address (i2c_regs_t *I2Cx, uint32_t own_address, uint32_t own_addr_size)
| Set the Own Address. More...
__STATIC_INLINE void | ll_i2c_set_clock_high_period_ss (i2c_regs_t *I2Cx, uint32_t count)
| Set the SCL clock high-period count for standard speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_high_period_ss (i2c_regs_t *I2Cx)
| Get the SCL clock high-period count for standard speed. More...
__STATIC_INLINE void | ll_i2c_set_clock_low_period_ss (i2c_regs_t *I2Cx, uint32_t count)
| Set the SCL clock low-period count for standard speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_low_period_ss (i2c_regs_t *I2Cx)
| Get the SCL clock low-period count for standard speed. More...
__STATIC_INLINE void | ll_i2c_set_clock_high_period_fs (i2c_regs_t *I2Cx, uint32_t count)
| Set the SCL clock high-period count for fast speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_high_period_fs (i2c_regs_t *I2Cx)
| Get the SCL clock high-period count for fast speed. More...
__STATIC_INLINE void | ll_i2c_set_clock_low_period_fs (i2c_regs_t *I2Cx, uint32_t count)
| Set the SCL clock low-period count for fast speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_low_period_fs (i2c_regs_t *I2Cx)
| Get the SCL clock low-period count for fast speed. More...
__STATIC_INLINE void | ll_i2c_set_clock_high_period_hs (i2c_regs_t *I2Cx, uint32_t count)
| Get the SCL clock high-period count for high speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_high_period_hs (i2c_regs_t *I2Cx)
| Get the SCL clock high-period count for high speed. More...
__STATIC_INLINE void | ll_i2c_set_clock_low_period_hs (i2c_regs_t *I2Cx, uint32_t count)
| Get the SCL clock low-period count for high speed. More...
__STATIC_INLINE uint32_t | ll_i2c_get_clock_low_period_hs (i2c_regs_t *I2Cx)
| Get the SCL clock low-period count for high speed. More...
__STATIC_INLINE void | ll_i2c_set_spike_len_fs (i2c_regs_t *I2Cx, uint32_t length)
| Set the spike len in fast speed mode. More...
__STATIC_INLINE uint32_t | ll_i2c_get_spike_len_fs (i2c_regs_t *I2Cx)
| Get the spike len in fast speed mode. More...
__STATIC_INLINE void | ll_i2c_set_spike_len_hs (i2c_regs_t *I2Cx, uint32_t length)
| Set the spike len in high speed mode. More...
__STATIC_INLINE uint32_t | ll_i2c_get_spike_len_hs (i2c_regs_t *I2Cx)
| Get the spike len in high speed mode. More...
__STATIC_INLINE void | ll_i2c_set_speed_mode (i2c_regs_t *I2Cx, uint32_t speed_mode)
| Set I2C Speed mode. More...
__STATIC_INLINE uint32_t | ll_i2c_get_speed_mode (i2c_regs_t *I2Cx)
| Get I2C Speed mode. More...
__STATIC_INLINE void | ll_i2c_set_high_speed_master_code (i2c_regs_t *I2Cx, uint32_t code)
| Set I2C High Speed Master Code Address. More...
__STATIC_INLINE uint32_t | ll_i2c_get_high_speed_master_code (i2c_regs_t *I2Cx)
| Get I2C Speed mode. More...
__STATIC_INLINE void | ll_i2c_set_data_tx_hold_time (i2c_regs_t *I2Cx, uint32_t time)
| Set the required transmit SDA hold time in units of ic_clk period. More...
__STATIC_INLINE uint32_t | ll_i2c_get_data_tx_hold_time (i2c_regs_t *I2Cx)
| Get the required transmit SDA hold time in units of ic_clk period. More...
__STATIC_INLINE void | ll_i2c_set_data_rx_hold_time (i2c_regs_t *I2Cx, uint32_t time)
| Set the required receive SDA hold time in units of ic_clk period. More...
__STATIC_INLINE uint32_t | ll_i2c_get_data_rx_hold_time (i2c_regs_t *I2Cx)
| Get the required receive SDA hold time in units of ic_clk period. More...
__STATIC_INLINE void | ll_i2c_set_data_setup_time (i2c_regs_t *I2Cx, uint32_t time)
| Set the SDA setup time when operating as a slave transmitter. More...
__STATIC_INLINE uint32_t | ll_i2c_get_data_setup_time (i2c_regs_t *I2Cx)
| Get the SDA setup time when operating as a slave transmitter. More...
__STATIC_INLINE void | ll_i2c_set_tx_fifo_threshold (i2c_regs_t *I2Cx, uint32_t threshold)
| Set threshold of entries (or below) that trigger the TX_EMPTY interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_get_tx_fifo_threshold (i2c_regs_t *I2Cx)
| Get threshold of TX FIFO that triggers an THRE interrupt. More...
__STATIC_INLINE void | ll_i2c_set_rx_fifo_threshold (i2c_regs_t *I2Cx, uint32_t threshold)
| Set threshold of RX FIFO that triggers an RDA interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_get_rx_fifo_threshold (i2c_regs_t *I2Cx)
| Get threshold of RX FIFO that triggers an RDA interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_get_tx_fifo_level (i2c_regs_t *I2Cx)
| Get FIFO Transmission Level. More...
__STATIC_INLINE uint32_t | ll_i2c_get_rx_fifo_level (i2c_regs_t *I2Cx)
| Get FIFO reception Level. More...
__STATIC_INLINE void | ll_i2c_enable_transfer_abort (i2c_regs_t *I2Cx)
| Enable DMA reception requests. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_transfer_abort (i2c_regs_t *I2Cx)
| Check if DMA reception requests are enabled or disabled. More...
__STATIC_INLINE uint32_t | ll_i2c_get_abort_source (i2c_regs_t *I2Cx)
| Get the transmit abort source. More...
__STATIC_INLINE uint32_t | ll_i2c_get_tx_flush_count (i2c_regs_t *I2Cx)
| Get the number of Tx FIFO Data Commands which are flushed due to TX_ABRT interrupt. More...
__STATIC_INLINE void | ll_i2c_enable_it (i2c_regs_t *I2Cx, uint32_t mask)
| Enable specified interrupts. More...
__STATIC_INLINE void | ll_i2c_disable_it (i2c_regs_t *I2Cx, uint32_t mask)
| Disable specified interrupts. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it (i2c_regs_t *I2Cx, uint32_t mask)
| Check if the specified interrupts are enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_master_on_hold (i2c_regs_t *I2Cx)
| Enable MASTER_ON_HOLD interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_master_om_hold (i2c_regs_t *I2Cx)
| Disable MASTER_ON_HOLD interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_master_on_hold (i2c_regs_t *I2Cx)
| Check if the MASTER_ON_HOLD Interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_restart_det (i2c_regs_t *I2Cx)
| Enable RESTART_DET interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_restart_det (i2c_regs_t *I2Cx)
| Disable RESTART_DET interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_restart_det (i2c_regs_t *I2Cx)
| Check if the RESTART_DET Interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_gen_call (i2c_regs_t *I2Cx)
| Enable GEN_CALL interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_gen_call (i2c_regs_t *I2Cx)
| Disable GEN_CALL interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_gen_call (i2c_regs_t *I2Cx)
| Check if GEN_CALL interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_start_det (i2c_regs_t *I2Cx)
| Enable START_DET received interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_start_det (i2c_regs_t *I2Cx)
| Disable START_DET received interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_start_det (i2c_regs_t *I2Cx)
| Check if START_DET received interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_stop_det (i2c_regs_t *I2Cx)
| Enable STOP_DET interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_stop_det (i2c_regs_t *I2Cx)
| Disable STOP_DET interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_stop_det (i2c_regs_t *I2Cx)
| Check if STOP_DET interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_activity (i2c_regs_t *I2Cx)
| Enable ACTIVITY interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_activity (i2c_regs_t *I2Cx)
| Disable ACTIVITY interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_activity (i2c_regs_t *I2Cx)
| Check if ACTIVITY interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_rx_done (i2c_regs_t *I2Cx)
| Enable RX_DONE interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_rx_done (i2c_regs_t *I2Cx)
| Disable RX_DONE interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enable_it_rx_done (i2c_regs_t *I2Cx)
| Check if RX_DONE interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_rx_abort (i2c_regs_t *I2Cx)
| Enable TX_ABRT interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_tx_abort (i2c_regs_t *I2Cx)
| Disable TX_ABRT interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_tx_abort (i2c_regs_t *I2Cx)
| Check if TX_ABRT interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_read_req (i2c_regs_t *I2Cx)
| Enable RD_REQ interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_read_req (i2c_regs_t *I2Cx)
| Disable RD_REQ interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_read_req (i2c_regs_t *I2Cx)
| Check if RD_REQ interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_tx_empty (i2c_regs_t *I2Cx)
| Enable TX_EMPTY interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_tx_empty (i2c_regs_t *I2Cx)
| Disable TX_EMPTY interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_tx_empty (i2c_regs_t *I2Cx)
| Check if TX_EMPTY interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_tx_over (i2c_regs_t *I2Cx)
| Enable TX_OVER interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_tx_over (i2c_regs_t *I2Cx)
| Disable TX_OVER interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_tx_over (i2c_regs_t *I2Cx)
| Check if TX_OVER interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_rx_full (i2c_regs_t *I2Cx)
| Enable RX_FULL interrupt. More...
__STATIC_INLINE void | ll_i2c_disbale_it_rx_full (i2c_regs_t *I2Cx)
| Disable RX_FULL interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_ls_enabled_it_rx_full (i2c_regs_t *I2Cx)
| Check if RX_FULL interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_rx_over (i2c_regs_t *I2Cx)
| Enable RX_OVER interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_rx_over (i2c_regs_t *I2Cx)
| Disable RX_OVER interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_rx_over (i2c_regs_t *I2Cx)
| Check if RX_OVER interrupt is enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_it_rx_under (i2c_regs_t *I2Cx)
| Enable RX_UNDER interrupt. More...
__STATIC_INLINE void | ll_i2c_disable_it_rx_under (i2c_regs_t *I2Cx)
| Disable RX_UNDER interrupt. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_it_rx_under (i2c_regs_t *I2Cx)
| Check if RX_UNDER interrupt is enabled or disabled. More...
__STATIC_INLINE uint32_t | ll_i2c_get_it_flag (i2c_regs_t *I2Cx)
| Get I2C interrupt flags. More...
__STATIC_INLINE uint32_t | ll_i2c_get_raw_it_flag (i2c_regs_t *I2Cx)
| Get I2C RAW interrupt flags. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_master_on_hold (i2c_regs_t *I2Cx)
| Indicate the status of MST_ON_HOLD flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_master_on_hold (i2c_regs_t *I2Cx)
| Indicate the status of RAW_MST_ON_HOLD flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_restart_det (i2c_regs_t *I2Cx)
| Indicate the status of RESTART_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_restart_det (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RESTART_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_gen_call (i2c_regs_t *I2Cx)
| Indicate the status of GEN_CALL flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_gen_call (i2c_regs_t *I2Cx)
| Indicate the status of RAW_GEN_CALL flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_start_det (i2c_regs_t *I2Cx)
| Indicate the status of START_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_start_det (i2c_regs_t *I2Cx)
| Indicate the status of RAW_START_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_stop_det (i2c_regs_t *I2Cx)
| Indicate the status of STOP_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_stop_det (i2c_regs_t *I2Cx)
| Indicate the status of RAW_STOP_DET flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_activity (i2c_regs_t *I2Cx)
| Indicate the status of ACTIVITY flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_activity (i2c_regs_t *I2Cx)
| Indicate the status of RAW_ACTIVITY flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_rx_done (i2c_regs_t *I2Cx)
| Indicate the status of RX_DONE flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_rx_done (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RX_DONE flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_tx_abort (i2c_regs_t *I2Cx)
| Indicate the status of TX_ABRT flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_tx_abort (i2c_regs_t *I2Cx)
| Indicate the status of RAW_TX_ABRT flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_read_req (i2c_regs_t *I2Cx)
| Indicate the status of RD_REQ flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_read_req (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RD_REQ flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_tx_empty (i2c_regs_t *I2Cx)
| Indicate the status of TX_EMPTY flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_tx_empty (i2c_regs_t *I2Cx)
| Indicate the status of RAW_TX_EMPTY flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_tx_over (i2c_regs_t *I2Cx)
| Indicate the status of TX_OVER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_tx_over (i2c_regs_t *I2Cx)
| Indicate the status of RAW_TX_OVER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_rx_full (i2c_regs_t *I2Cx)
| Indicate the status of RX_FULL flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_rx_full (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RX_FULL flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_rx_over (i2c_regs_t *I2Cx)
| Indicate the status of RX_OVER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_rx_over (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RX_OVER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_rx_under (i2c_regs_t *I2Cx)
| Indicate the status of RX_UNDER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_raw_rx_under (i2c_regs_t *I2Cx)
| Indicate the status of RAW_RX_UNDER flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_intr (i2c_regs_t *I2Cx)
| Clear the combined interrupt, all individual interrupts, and the IC_TX_ABRT_SOURCE register. More...
__STATIC_INLINE void | ll_i2c_clear_flag_gen_call (i2c_regs_t *I2Cx)
| Clear GEN_CALL flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_start_det (i2c_regs_t *I2Cx)
| Clear START_DET flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_stop_det (i2c_regs_t *I2Cx)
| Clear STOP_DET flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_activity (i2c_regs_t *I2Cx)
| Clear ACTIVITY flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_rx_done (i2c_regs_t *I2Cx)
| Clear RX_DONE flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_tx_abort (i2c_regs_t *I2Cx)
| Clear TX_ABRT flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_read_req (i2c_regs_t *I2Cx)
| Clear RD_REQ flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_tx_over (i2c_regs_t *I2Cx)
| Clear TX_OVER flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_rx_over (i2c_regs_t *I2Cx)
| Clear RX_OVER flag. More...
__STATIC_INLINE void | ll_i2c_clear_flag_rx_under (i2c_regs_t *I2Cx)
| Clear RX_UNDER flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_slave_activity (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Slave FSM Activity Status flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_master_activity (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Master FSM Activity Status flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_rff (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Receive FIFO Completely Full flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_rfne (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Receive FIFO Not Empty flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_tfe (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Transmit FIFO Completely Empty flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_tfnf (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS Transmit FIFO Not Full flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_status_activity (i2c_regs_t *I2Cx)
| Indicate the status of IC_STATUS ACTIVITY flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_slave_rx_data_lost (i2c_regs_t *I2Cx)
| Indicate the status of Slave Received Data Lost flag. More...
__STATIC_INLINE uint32_t | ll_i2c_is_active_flag_slave_dis_whl_busy (i2c_regs_t *I2Cx)
| Indicate the status of Slave Disabled While Busy flag. More...
__STATIC_INLINE void | ll_i2c_enable_dma_req_tx (i2c_regs_t *I2Cx)
| Enable DMA transmission requests. More...
__STATIC_INLINE void | ll_i2c_disable_dma_req_tx (i2c_regs_t *I2Cx)
| Disable DMA transmission requests. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_dma_req_tx (i2c_regs_t *I2Cx)
| Check if DMA transmission requests are enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_enable_dma_req_rx (i2c_regs_t *I2Cx)
| Enable DMA reception requests. More...
__STATIC_INLINE void | ll_i2c_disable_dma_req_rx (i2c_regs_t *I2Cx)
| Disable DMA reception requests. More...
__STATIC_INLINE uint32_t | ll_i2c_is_enabled_dma_req_rx (i2c_regs_t *I2Cx)
| Check if DMA reception requests are enabled or disabled. More...
__STATIC_INLINE void | ll_i2c_set_dma_tx_data_level (i2c_regs_t *I2Cx, uint32_t level)
| Set level of TX FIFO that requests a DMA transmit. More...
__STATIC_INLINE uint32_t | ll_i2c_get_dma_tx_data_level (i2c_regs_t *I2Cx)
| Get level of TX FIFO that request a DMA transmit. More...
__STATIC_INLINE void | ll_i2c_set_dma_rx_data_level (i2c_regs_t *I2Cx, uint32_t level)
| Set level of RX FIFO that requests a DMA receive. More...
__STATIC_INLINE uint32_t | ll_i2c_get_dma_rx_data_level (i2c_regs_t *I2Cx)
| Get level of RX FIFO that request a DMA receive. More...
__STATIC_INLINE uint32_t | ll_i2c_dma_get_register_address (i2c_regs_t *I2Cx)
| Get the data register address used for DMA transfer. More...
__STATIC_INLINE void | ll_i2c_set_slave_address (i2c_regs_t *I2Cx, uint32_t slave_addr)
| Configure the slave address for transfer (master mode). More...
__STATIC_INLINE uint32_t | ll_i2c_get_slave_address (i2c_regs_t *I2Cx)
| Get the slave address programmed for transfer (master mode). More...
__STATIC_INLINE void | ll_i2c_handle_transfer (i2c_regs_t *I2Cx, uint32_t slave_addr, uint32_t slave_addr_size)
| Handles I2Cx communication when starting transfer or during transfer (TC or TCR flag are set). More...
__STATIC_INLINE uint32_t | ll_i2c_get_transfer_direction (i2c_regs_t *I2Cx)
| Indicate the value of transfer direction (slave mode). More...
__STATIC_INLINE uint8_t | ll_i2c_receive_data8 (i2c_regs_t *I2Cx)
| Read Receive Data register. More...
__STATIC_INLINE void | ll_i2c_transmit_data8 (i2c_regs_t *I2Cx, uint8_t data, uint32_t cmd)
| Write in Transmit Data Register . More...
error_status_t | ll_i2c_deinit (i2c_regs_t *I2Cx)
| De-initialize I2C registers (Registers restored to their default values). More...
error_status_t | ll_i2c_init (i2c_regs_t *I2Cx, ll_i2c_init_t *p_i2c_init)
| Initialize I2C registers according to the specified parameters in p_i2c_init. More...
void | ll_i2c_struct_init (ll_i2c_init_t *p_i2c_init)
| Set each field of a ll_i2c_init_t type structure to default value. More...

## Detailed Description

Header file containing functions prototypes of I2C LL library.

Author
  BLE Driver Team

Attention

  ##### Copyright (c) 2019 GOODIX

All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of GOODIX nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.