STM32F769IDiscovery  1.00
uDANTE Audio Networking with STM32F7 DISCO board
Macros
SPI Exported Macros

Macros

#define __HAL_SPI_RESET_HANDLE_STATE(__HANDLE__)   ((__HANDLE__)->State = HAL_SPI_STATE_RESET)
 Reset SPI handle state. More...
 
#define __HAL_SPI_ENABLE_IT(__HANDLE__, __INTERRUPT__)    ((__HANDLE__)->Instance->CR2 |= (__INTERRUPT__))
 Enables or disables the specified SPI interrupts. More...
 
#define __HAL_SPI_DISABLE_IT(__HANDLE__, __INTERRUPT__)   ((__HANDLE__)->Instance->CR2 &= (~(__INTERRUPT__)))
 
#define __HAL_SPI_GET_IT_SOURCE(__HANDLE__, __INTERRUPT__)   ((((__HANDLE__)->Instance->CR2 & (__INTERRUPT__)) == (__INTERRUPT__)) ? SET : RESET)
 Checks if the specified SPI interrupt source is enabled or disabled. More...
 
#define __HAL_SPI_GET_FLAG(__HANDLE__, __FLAG__)   ((((__HANDLE__)->Instance->SR) & (__FLAG__)) == (__FLAG__))
 Checks whether the specified SPI flag is set or not. More...
 
#define __HAL_SPI_CLEAR_CRCERRFLAG(__HANDLE__)   ((__HANDLE__)->Instance->SR = (uint16_t)(~SPI_FLAG_CRCERR))
 Clears the SPI CRCERR pending flag. More...
 
#define __HAL_SPI_CLEAR_MODFFLAG(__HANDLE__)
 Clears the SPI MODF pending flag. More...
 
#define __HAL_SPI_CLEAR_OVRFLAG(__HANDLE__)
 Clears the SPI OVR pending flag. More...
 
#define __HAL_SPI_CLEAR_FREFLAG(__HANDLE__)
 Clears the SPI FRE pending flag. More...
 
#define __HAL_SPI_ENABLE(__HANDLE__)   ((__HANDLE__)->Instance->CR1 |= SPI_CR1_SPE)
 Enables the SPI. More...
 
#define __HAL_SPI_DISABLE(__HANDLE__)   ((__HANDLE__)->Instance->CR1 &= (~SPI_CR1_SPE))
 Disables the SPI. More...
 

Detailed Description

Macro Definition Documentation

#define __HAL_SPI_CLEAR_CRCERRFLAG (   __HANDLE__)    ((__HANDLE__)->Instance->SR = (uint16_t)(~SPI_FLAG_CRCERR))

Clears the SPI CRCERR pending flag.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 463 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_CLEAR_FREFLAG (   __HANDLE__)
Value:
do{ \
__IO uint32_t tmpreg; \
tmpreg = (__HANDLE__)->Instance->SR; \
UNUSED(tmpreg); \
} while(0)
#define UNUSED(x)

Clears the SPI FRE pending flag.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 499 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_CLEAR_MODFFLAG (   __HANDLE__)
Value:
do{ \
__IO uint32_t tmpreg; \
tmpreg = (__HANDLE__)->Instance->SR; \
(__HANDLE__)->Instance->CR1 &= (~SPI_CR1_SPE); \
UNUSED(tmpreg); \
} while(0)
#define SPI_CR1_SPE
Definition: stm32f745xx.h:6597

Clears the SPI MODF pending flag.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 471 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_CLEAR_OVRFLAG (   __HANDLE__)
Value:
do{ \
__IO uint32_t tmpreg; \
tmpreg = (__HANDLE__)->Instance->DR; \
tmpreg = (__HANDLE__)->Instance->SR; \
UNUSED(tmpreg); \
} while(0)

Clears the SPI OVR pending flag.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 485 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_DISABLE (   __HANDLE__)    ((__HANDLE__)->Instance->CR1 &= (~SPI_CR1_SPE))

Disables the SPI.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 518 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_DISABLE_IT (   __HANDLE__,
  __INTERRUPT__ 
)    ((__HANDLE__)->Instance->CR2 &= (~(__INTERRUPT__)))

Definition at line 426 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_ENABLE (   __HANDLE__)    ((__HANDLE__)->Instance->CR1 |= SPI_CR1_SPE)

Enables the SPI.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
Return values
None

Definition at line 511 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_ENABLE_IT (   __HANDLE__,
  __INTERRUPT__ 
)    ((__HANDLE__)->Instance->CR2 |= (__INTERRUPT__))

Enables or disables the specified SPI interrupts.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
<strong>INTERRUPT</strong>: specifies the interrupt source to enable or disable. This parameter can be one of the following values:
  • SPI_IT_TXE: Tx buffer empty interrupt enable
  • SPI_IT_RXNE: RX buffer not empty interrupt enable
  • SPI_IT_ERR: Error interrupt enable
Return values
None

Definition at line 425 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_GET_FLAG (   __HANDLE__,
  __FLAG__ 
)    ((((__HANDLE__)->Instance->SR) & (__FLAG__)) == (__FLAG__))

Checks whether the specified SPI flag is set or not.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
<strong>FLAG</strong>: specifies the flag to check. This parameter can be one of the following values:
  • SPI_FLAG_RXNE: Receive buffer not empty flag
  • SPI_FLAG_TXE: Transmit buffer empty flag
  • SPI_FLAG_CRCERR: CRC error flag
  • SPI_FLAG_MODF: Mode fault flag
  • SPI_FLAG_OVR: Overrun flag
  • SPI_FLAG_BSY: Busy flag
  • SPI_FLAG_FRE: Frame format error flag
  • SPI_FLAG_FTLVL: SPI fifo transmission level
  • SPI_FLAG_FRLVL: SPI fifo reception level
Return values
Thenew state of FLAG (TRUE or FALSE).

Definition at line 456 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_GET_IT_SOURCE (   __HANDLE__,
  __INTERRUPT__ 
)    ((((__HANDLE__)->Instance->CR2 & (__INTERRUPT__)) == (__INTERRUPT__)) ? SET : RESET)

Checks if the specified SPI interrupt source is enabled or disabled.

Parameters
<strong>HANDLE</strong>: specifies the SPI Handle. This parameter can be SPI where x: 1, 2, or 3 to select the SPI peripheral.
<strong>INTERRUPT</strong>: specifies the SPI interrupt source to check. This parameter can be one of the following values:
  • SPI_IT_TXE: Tx buffer empty interrupt enable
  • SPI_IT_RXNE: RX buffer not empty interrupt enable
  • SPI_IT_ERR: Error interrupt enable
Return values
Thenew state of IT (TRUE or FALSE).

Definition at line 438 of file stm32f7xx_hal_spi.h.

#define __HAL_SPI_RESET_HANDLE_STATE (   __HANDLE__)    ((__HANDLE__)->State = HAL_SPI_STATE_RESET)

Reset SPI handle state.

Parameters
<strong>HANDLE</strong>SPI handle.
Return values
None

Definition at line 413 of file stm32f7xx_hal_spi.h.