RTEMS 6.1-rc6
Loading...
Searching...
No Matches
Macros

Macros

#define IS_I2C_ADDRESSING_MODE(MODE)
 
#define IS_I2C_DUAL_ADDRESS(ADDRESS)
 
#define IS_I2C_OWN_ADDRESS2_MASK(MASK)
 
#define IS_I2C_GENERAL_CALL(CALL)
 
#define IS_I2C_NO_STRETCH(STRETCH)
 
#define IS_I2C_MEMADD_SIZE(SIZE)
 
#define IS_TRANSFER_MODE(MODE)
 
#define IS_TRANSFER_REQUEST(REQUEST)
 
#define IS_I2C_TRANSFER_OPTIONS_REQUEST(REQUEST)
 
#define IS_I2C_TRANSFER_OTHER_OPTIONS_REQUEST(REQUEST)
 
#define I2C_RESET_CR2(__HANDLE__)
 
#define I2C_GET_ADDR_MATCH(__HANDLE__)
 
#define I2C_GET_DIR(__HANDLE__)
 
#define I2C_GET_STOP_MODE(__HANDLE__)   ((__HANDLE__)->Instance->CR2 & I2C_CR2_AUTOEND)
 
#define I2C_GET_OWN_ADDRESS1(__HANDLE__)   ((uint16_t)((__HANDLE__)->Instance->OAR1 & I2C_OAR1_OA1))
 
#define I2C_GET_OWN_ADDRESS2(__HANDLE__)   ((uint16_t)((__HANDLE__)->Instance->OAR2 & I2C_OAR2_OA2))
 
#define IS_I2C_OWN_ADDRESS1(ADDRESS1)   ((ADDRESS1) <= 0x000003FFU)
 
#define IS_I2C_OWN_ADDRESS2(ADDRESS2)   ((ADDRESS2) <= (uint16_t)0x00FFU)
 
#define I2C_MEM_ADD_MSB(__ADDRESS__)
 
#define I2C_MEM_ADD_LSB(__ADDRESS__)   ((uint8_t)((uint16_t)((__ADDRESS__) & (uint16_t)(0x00FFU))))
 
#define I2C_GENERATE_START(__ADDMODE__, __ADDRESS__)
 
#define I2C_CHECK_FLAG(__ISR__, __FLAG__)
 
#define I2C_CHECK_IT_SOURCE(__CR1__, __IT__)   ((((__CR1__) & (__IT__)) == (__IT__)) ? SET : RESET)
 

Detailed Description

Macro Definition Documentation

◆ I2C_CHECK_FLAG

#define I2C_CHECK_FLAG (   __ISR__,
  __FLAG__ 
)
Value:
((((__ISR__) & ((__FLAG__) & I2C_FLAG_MASK)) == \
((__FLAG__) & I2C_FLAG_MASK)) ? SET : RESET)
#define I2C_FLAG_MASK
Check whether the specified I2C flag is set or not.
Definition: stm32h7xx_hal_i2c.h:563

◆ I2C_GENERATE_START

#define I2C_GENERATE_START (   __ADDMODE__,
  __ADDRESS__ 
)
Value:
(((__ADDMODE__) == I2C_ADDRESSINGMODE_7BIT) ? \
(uint32_t)((((uint32_t)(__ADDRESS__) & (I2C_CR2_SADD)) | \
(~I2C_CR2_RD_WRN)) : \
(uint32_t)((((uint32_t)(__ADDRESS__) & (I2C_CR2_SADD)) | \
#define I2C_CR2_SADD
Definition: stm32h723xx.h:13017
#define I2C_CR2_RD_WRN
Definition: stm32h723xx.h:13020
#define I2C_CR2_ADD10
Definition: stm32h723xx.h:13023
#define I2C_CR2_START
Definition: stm32h723xx.h:13029
#define I2C_CR2_AUTOEND
Definition: stm32h723xx.h:13044

◆ I2C_GET_ADDR_MATCH

#define I2C_GET_ADDR_MATCH (   __HANDLE__)
Value:
((uint16_t)(((__HANDLE__)->Instance->ISR & I2C_ISR_ADDCODE) \
>> 16U))
#define I2C_ISR_ADDCODE
Definition: stm32h723xx.h:13178

◆ I2C_GET_DIR

#define I2C_GET_DIR (   __HANDLE__)
Value:
((uint8_t)(((__HANDLE__)->Instance->ISR & I2C_ISR_DIR) \
>> 16U))
#define I2C_ISR_DIR
Definition: stm32h723xx.h:13175

◆ I2C_MEM_ADD_MSB

#define I2C_MEM_ADD_MSB (   __ADDRESS__)
Value:
((uint8_t)((uint16_t)(((uint16_t)((__ADDRESS__) & \
(uint16_t)(0xFF00U))) >> 8U)))

◆ I2C_RESET_CR2

#define I2C_RESET_CR2 (   __HANDLE__)
Value:
((__HANDLE__)->Instance->CR2 &= \
(uint32_t)~((uint32_t)(I2C_CR2_SADD | I2C_CR2_HEAD10R | \
#define I2C_CR2_RELOAD
Definition: stm32h723xx.h:13041
#define I2C_CR2_NBYTES
Definition: stm32h723xx.h:13038
#define I2C_CR2_HEAD10R
Definition: stm32h723xx.h:13026

◆ IS_I2C_ADDRESSING_MODE

#define IS_I2C_ADDRESSING_MODE (   MODE)
Value:
(((MODE) == I2C_ADDRESSINGMODE_7BIT) || \
((MODE) == I2C_ADDRESSINGMODE_10BIT))

◆ IS_I2C_DUAL_ADDRESS

#define IS_I2C_DUAL_ADDRESS (   ADDRESS)
Value:
(((ADDRESS) == I2C_DUALADDRESS_DISABLE) || \
((ADDRESS) == I2C_DUALADDRESS_ENABLE))

◆ IS_I2C_GENERAL_CALL

#define IS_I2C_GENERAL_CALL (   CALL)
Value:
(((CALL) == I2C_GENERALCALL_DISABLE) || \
((CALL) == I2C_GENERALCALL_ENABLE))

◆ IS_I2C_MEMADD_SIZE

#define IS_I2C_MEMADD_SIZE (   SIZE)
Value:
(((SIZE) == I2C_MEMADD_SIZE_8BIT) || \
((SIZE) == I2C_MEMADD_SIZE_16BIT))

◆ IS_I2C_NO_STRETCH

#define IS_I2C_NO_STRETCH (   STRETCH)
Value:
(((STRETCH) == I2C_NOSTRETCH_DISABLE) || \
((STRETCH) == I2C_NOSTRETCH_ENABLE))

◆ IS_I2C_OWN_ADDRESS2_MASK

#define IS_I2C_OWN_ADDRESS2_MASK (   MASK)
Value:
(((MASK) == I2C_OA2_NOMASK) || \
((MASK) == I2C_OA2_MASK01) || \
((MASK) == I2C_OA2_MASK02) || \
((MASK) == I2C_OA2_MASK03) || \
((MASK) == I2C_OA2_MASK04) || \
((MASK) == I2C_OA2_MASK05) || \
((MASK) == I2C_OA2_MASK06) || \
((MASK) == I2C_OA2_MASK07))

◆ IS_I2C_TRANSFER_OPTIONS_REQUEST

#define IS_I2C_TRANSFER_OPTIONS_REQUEST (   REQUEST)
Value:
(((REQUEST) == I2C_FIRST_FRAME) || \
((REQUEST) == I2C_FIRST_AND_NEXT_FRAME) || \
((REQUEST) == I2C_NEXT_FRAME) || \
((REQUEST) == I2C_FIRST_AND_LAST_FRAME) || \
((REQUEST) == I2C_LAST_FRAME) || \
((REQUEST) == I2C_LAST_FRAME_NO_STOP) || \
IS_I2C_TRANSFER_OTHER_OPTIONS_REQUEST(REQUEST))

◆ IS_I2C_TRANSFER_OTHER_OPTIONS_REQUEST

#define IS_I2C_TRANSFER_OTHER_OPTIONS_REQUEST (   REQUEST)
Value:
(((REQUEST) == I2C_OTHER_FRAME) || \
((REQUEST) == I2C_OTHER_AND_LAST_FRAME))

◆ IS_TRANSFER_MODE

#define IS_TRANSFER_MODE (   MODE)
Value:
(((MODE) == I2C_RELOAD_MODE) || \
((MODE) == I2C_AUTOEND_MODE) || \
((MODE) == I2C_SOFTEND_MODE))

◆ IS_TRANSFER_REQUEST

#define IS_TRANSFER_REQUEST (   REQUEST)
Value:
(((REQUEST) == I2C_GENERATE_STOP) || \
((REQUEST) == I2C_GENERATE_START_READ) || \
((REQUEST) == I2C_GENERATE_START_WRITE) || \
((REQUEST) == I2C_NO_STARTSTOP))