Symbols
loading...
Files
loading...

SPI_HandleTypeDef struct

SPI handle Structure definition

Syntax

typedef struct __SPI_HandleTypeDef {   SPI_TypeDef                *Instance;         SPI_InitTypeDef            Init;              uint8_t                    *pTxBuffPtr;       uint16_t                   TxXferSize;        __IO uint16_t              TxXferCount;       uint8_t                    *pRxBuffPtr;       uint16_t                   RxXferSize;        __IO uint16_t              RxXferCount;       void (*RxISR)(struct __SPI_HandleTypeDef *hspi);      void (*TxISR)(struct __SPI_HandleTypeDef *hspi);      DMA_HandleTypeDef          *hdmatx;           DMA_HandleTypeDef          *hdmarx;           HAL_LockTypeDef            Lock;              __IO HAL_SPI_StateTypeDef  State;             __IO uint32_t              ErrorCode;       #if (USE_HAL_SPI_REGISTER_CALLBACKS == 1U)   void (* TxCpltCallback)(struct __SPI_HandleTypeDef *hspi);                void (* RxCpltCallback)(struct __SPI_HandleTypeDef *hspi);                void (* TxRxCpltCallback)(struct __SPI_HandleTypeDef *hspi);              void (* TxHalfCpltCallback)(struct __SPI_HandleTypeDef *hspi);            void (* RxHalfCpltCallback)(struct __SPI_HandleTypeDef *hspi);            void (* TxRxHalfCpltCallback)(struct __SPI_HandleTypeDef *hspi);          void (* ErrorCallback)(struct __SPI_HandleTypeDef *hspi);                 void (* AbortCpltCallback)(struct __SPI_HandleTypeDef *hspi);             void (* MspInitCallback)(struct __SPI_HandleTypeDef *hspi);               void (* MspDeInitCallback)(struct __SPI_HandleTypeDef *hspi);           #endif   } SPI_HandleTypeDef;

Fields

Instance

SPI registers base address. Read more...

Init

SPI communication parameters. Read more...

pTxBuffPtr

Pointer to SPI Tx transfer Buffer. Read more...

TxXferSize

SPI Tx Transfer size. Read more...

TxXferCount

SPI Tx Transfer Counter. Read more...

pRxBuffPtr

Pointer to SPI Rx transfer Buffer. Read more...

RxXferSize

SPI Rx Transfer size. Read more...

RxXferCount

SPI Rx Transfer Counter. Read more...

RxISR

function pointer on Rx ISR. Read more...

TxISR

function pointer on Tx ISR. Read more...

hdmatx

SPI Tx DMA Handle parameters. Read more...

hdmarx

SPI Rx DMA Handle parameters. Read more...

Lock

Locking object. Read more...

State

SPI communication state. Read more...

ErrorCode

SPI Error code. Read more...

Examples

SPI_HandleTypeDef is referenced by 44 libraries and example projects.

References

LocationReferrerScopeText
stm32f4xx_hal_spi.h:104
typedef struct __SPI_HandleTypeDef
stm32f4xx_hal_spi.h:149
stm32f4xx_hal_spi.c:239SPI_WaitFlagStateUntilTimeout()::hspiSPI_WaitFlagStateUntilTimeout()
stm32f4xx_hal_spi.c:241SPI_TxISR_8BIT()::hspiSPI_TxISR_8BIT()
static void SPI_TxISR_8BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:242SPI_TxISR_16BIT()::hspiSPI_TxISR_16BIT()
static void SPI_TxISR_16BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:243SPI_RxISR_8BIT()::hspiSPI_RxISR_8BIT()
static void SPI_RxISR_8BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:244SPI_RxISR_16BIT()::hspiSPI_RxISR_16BIT()
static void SPI_RxISR_16BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:245SPI_2linesRxISR_8BIT()::hspiSPI_2linesRxISR_8BIT()
static void SPI_2linesRxISR_8BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:246SPI_2linesTxISR_8BIT()::hspiSPI_2linesTxISR_8BIT()
static void SPI_2linesTxISR_8BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:247SPI_2linesTxISR_16BIT()::hspiSPI_2linesTxISR_16BIT()
static void SPI_2linesTxISR_16BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:248SPI_2linesRxISR_16BIT()::hspiSPI_2linesRxISR_16BIT()
static void SPI_2linesRxISR_16BIT(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:250SPI_RxISR_8BITCRC()::hspiSPI_RxISR_8BITCRC()
static void SPI_RxISR_8BITCRC(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:251SPI_RxISR_16BITCRC()::hspiSPI_RxISR_16BITCRC()
static void SPI_RxISR_16BITCRC(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:252SPI_2linesRxISR_8BITCRC()::hspiSPI_2linesRxISR_8BITCRC()
static void SPI_2linesRxISR_8BITCRC(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:253SPI_2linesRxISR_16BITCRC()::hspiSPI_2linesRxISR_16BITCRC()
static void SPI_2linesRxISR_16BITCRC(struct __SPI_HandleTypeDef *hspi);
stm32f4xx_hal_spi.c:255SPI_AbortRx_ISR()::hspiSPI_AbortRx_ISR()
stm32f4xx_hal_spi.c:256SPI_AbortTx_ISR()::hspiSPI_AbortTx_ISR()
stm32f4xx_hal_spi.c:257SPI_CloseRxTx_ISR()::hspiSPI_CloseRxTx_ISR()
stm32f4xx_hal_spi.c:258SPI_CloseRx_ISR()::hspiSPI_CloseRx_ISR()
stm32f4xx_hal_spi.c:259SPI_CloseTx_ISR()::hspiSPI_CloseTx_ISR()
stm32f4xx_hal_spi.c:260SPI_EndRxTransaction()::hspiSPI_EndRxTransaction()
stm32f4xx_hal_spi.c:261SPI_EndRxTxTransaction()::hspiSPI_EndRxTxTransaction()
stm32f4xx_hal_spi.c:311HAL_SPI_Init()::hspiHAL_SPI_Init()
stm32f4xx_hal_spi.c:437HAL_SPI_DeInit()::hspiHAL_SPI_DeInit()
stm32f4xx_hal_spi.c:481HAL_SPI_MspInit()::hspiHAL_SPI_MspInit()
stm32f4xx_hal_spi.c:497HAL_SPI_MspDeInit()::hspiHAL_SPI_MspDeInit()
stm32f4xx_hal_spi.c:769HAL_SPI_Transmit()::hspiHAL_SPI_Transmit()
stm32f4xx_hal_spi.c:939HAL_SPI_Receive()::hspiHAL_SPI_Receive()
stm32f4xx_hal_spi.c:1142HAL_SPI_TransmitReceive()::hspiHAL_SPI_TransmitReceive()
stm32f4xx_hal_spi.c:1393HAL_SPI_Transmit_IT()::hspiHAL_SPI_Transmit_IT()
stm32f4xx_hal_spi.c:1479HAL_SPI_Receive_IT()::hspiHAL_SPI_Receive_IT()
stm32f4xx_hal_spi.c:1575HAL_SPI_TransmitReceive_IT()::hspiHAL_SPI_TransmitReceive_IT()
stm32f4xx_hal_spi.c:1664HAL_SPI_Transmit_DMA()::hspiHAL_SPI_Transmit_DMA()
stm32f4xx_hal_spi.c:1771HAL_SPI_Receive_DMA()::hspiHAL_SPI_Receive_DMA()
stm32f4xx_hal_spi.c:1885HAL_SPI_TransmitReceive_DMA()::hspiHAL_SPI_TransmitReceive_DMA()
stm32f4xx_hal_spi.c:2029HAL_SPI_Abort()::hspiHAL_SPI_Abort()
stm32f4xx_hal_spi.c:2174HAL_SPI_Abort_IT()::hspiHAL_SPI_Abort_IT()
stm32f4xx_hal_spi.c:2335HAL_SPI_DMAPause()::hspiHAL_SPI_DMAPause()
stm32f4xx_hal_spi.c:2355HAL_SPI_DMAResume()::hspiHAL_SPI_DMAResume()
stm32f4xx_hal_spi.c:2375HAL_SPI_DMAStop()::hspiHAL_SPI_DMAStop()
stm32f4xx_hal_spi.c:2415HAL_SPI_IRQHandler()::hspiHAL_SPI_IRQHandler()
stm32f4xx_hal_spi.c:2522HAL_SPI_TxCpltCallback()::hspiHAL_SPI_TxCpltCallback()
stm32f4xx_hal_spi.c:2538HAL_SPI_RxCpltCallback()::hspiHAL_SPI_RxCpltCallback()
stm32f4xx_hal_spi.c:2554HAL_SPI_TxRxCpltCallback()::hspiHAL_SPI_TxRxCpltCallback()
stm32f4xx_hal_spi.c:2570HAL_SPI_TxHalfCpltCallback()::hspiHAL_SPI_TxHalfCpltCallback()
stm32f4xx_hal_spi.c:2586HAL_SPI_RxHalfCpltCallback()::hspiHAL_SPI_RxHalfCpltCallback()
stm32f4xx_hal_spi.c:2602HAL_SPI_TxRxHalfCpltCallback()::hspiHAL_SPI_TxRxHalfCpltCallback()
stm32f4xx_hal_spi.c:2618HAL_SPI_ErrorCallback()::hspiHAL_SPI_ErrorCallback()
stm32f4xx_hal_spi.c:2636HAL_SPI_AbortCpltCallback()::hspiHAL_SPI_AbortCpltCallback()
stm32f4xx_hal_spi.c:2671HAL_SPI_GetState()::hspiHAL_SPI_GetState()
stm32f4xx_hal_spi.c:2683HAL_SPI_GetError()::hspiHAL_SPI_GetError()
stm32f4xx_hal_spi.c:2710SPI_DMATransmitCplt()::hspiSPI_DMATransmitCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2767SPI_DMAReceiveCplt()::hspiSPI_DMAReceiveCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2856SPI_DMATransmitReceiveCplt()::hspiSPI_DMATransmitReceiveCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2936SPI_DMAHalfTransmitCplt()::hspiSPI_DMAHalfTransmitCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2954SPI_DMAHalfReceiveCplt()::hspiSPI_DMAHalfReceiveCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2972SPI_DMAHalfTransmitReceiveCplt()::hspiSPI_DMAHalfTransmitReceiveCplt()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:2990SPI_DMAError()::hspiSPI_DMAError()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:3013SPI_DMAAbortOnError()::hspiSPI_DMAAbortOnError()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:3035SPI_DMATxAbortCallback()::hspiSPI_DMATxAbortCallback()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:3100SPI_DMARxAbortCallback()::hspiSPI_DMARxAbortCallback()
SPI_HandleTypeDef *hspi = (SPI_HandleTypeDef *)(((DMA_HandleTypeDef *)hdma)->Parent); /* Derogation MISRAC2012-Rule-11.5 */
stm32f4xx_hal_spi.c:3157SPI_2linesRxISR_8BIT()
static void SPI_2linesRxISR_8BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3192SPI_2linesRxISR_8BITCRC()
static void SPI_2linesRxISR_8BITCRC(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3220SPI_2linesTxISR_8BIT()
static void SPI_2linesTxISR_8BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3256SPI_2linesRxISR_16BIT()
static void SPI_2linesRxISR_16BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3290SPI_2linesRxISR_16BITCRC()
static void SPI_2linesRxISR_16BITCRC(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3312SPI_2linesTxISR_16BIT()
static void SPI_2linesTxISR_16BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3350SPI_RxISR_8BITCRC()
static void SPI_RxISR_8BITCRC(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3372SPI_RxISR_8BIT()
static void SPI_RxISR_8BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3406SPI_RxISR_16BITCRC()
static void SPI_RxISR_16BITCRC(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3428SPI_RxISR_16BIT()
static void SPI_RxISR_16BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3461SPI_TxISR_8BIT()
static void SPI_TxISR_8BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3486SPI_TxISR_16BIT()
static void SPI_TxISR_16BIT(struct __SPI_HandleTypeDef *hspi)
stm32f4xx_hal_spi.c:3516SPI_WaitFlagStateUntilTimeout()::hspiSPI_WaitFlagStateUntilTimeout()
stm32f4xx_hal_spi.c:3583SPI_EndRxTransaction()::hspiSPI_EndRxTransaction()
stm32f4xx_hal_spi.c:3633SPI_EndRxTxTransaction()::hspiSPI_EndRxTxTransaction()
stm32f4xx_hal_spi.c:3680SPI_CloseRxTx_ISR()::hspiSPI_CloseRxTx_ISR()
stm32f4xx_hal_spi.c:3775SPI_CloseRx_ISR()::hspiSPI_CloseRx_ISR()
stm32f4xx_hal_spi.c:3838SPI_CloseTx_ISR()::hspiSPI_CloseTx_ISR()
stm32f4xx_hal_spi.c:3899SPI_AbortRx_ISR()::hspiSPI_AbortRx_ISR()
stm32f4xx_hal_spi.c:3935SPI_AbortTx_ISR()::hspiSPI_AbortTx_ISR()
stm32f4xx_hal_spi.h:122__SPI_HandleTypeDef::RxISR::hspi
void (*RxISR)(struct __SPI_HandleTypeDef *hspi); /*!< function pointer on Rx ISR */
stm32f4xx_hal_spi.h:124__SPI_HandleTypeDef::TxISR::hspi
void (*TxISR)(struct __SPI_HandleTypeDef *hspi); /*!< function pointer on Tx ISR */
stm32f4xx_hal_spi.h:149SPI_HandleTypeDef
stm32f4xx_hal_spi.h:651HAL_SPI_Init()::hspiHAL_SPI_Init()
stm32f4xx_hal_spi.h:652HAL_SPI_DeInit()::hspiHAL_SPI_DeInit()
stm32f4xx_hal_spi.h:653HAL_SPI_MspInit()::hspiHAL_SPI_MspInit()
stm32f4xx_hal_spi.h:654HAL_SPI_MspDeInit()::hspiHAL_SPI_MspDeInit()
stm32f4xx_hal_spi.h:670HAL_SPI_Transmit()::hspiHAL_SPI_Transmit()
stm32f4xx_hal_spi.h:671HAL_SPI_Receive()::hspiHAL_SPI_Receive()
stm32f4xx_hal_spi.h:672HAL_SPI_TransmitReceive()::hspiHAL_SPI_TransmitReceive()
stm32f4xx_hal_spi.h:674HAL_SPI_Transmit_IT()::hspiHAL_SPI_Transmit_IT()
stm32f4xx_hal_spi.h:675HAL_SPI_Receive_IT()::hspiHAL_SPI_Receive_IT()
stm32f4xx_hal_spi.h:676HAL_SPI_TransmitReceive_IT()::hspiHAL_SPI_TransmitReceive_IT()
stm32f4xx_hal_spi.h:678HAL_SPI_Transmit_DMA()::hspiHAL_SPI_Transmit_DMA()
stm32f4xx_hal_spi.h:679HAL_SPI_Receive_DMA()::hspiHAL_SPI_Receive_DMA()
stm32f4xx_hal_spi.h:680HAL_SPI_TransmitReceive_DMA()::hspiHAL_SPI_TransmitReceive_DMA()
stm32f4xx_hal_spi.h:682HAL_SPI_DMAPause()::hspiHAL_SPI_DMAPause()
stm32f4xx_hal_spi.h:683HAL_SPI_DMAResume()::hspiHAL_SPI_DMAResume()
stm32f4xx_hal_spi.h:684HAL_SPI_DMAStop()::hspiHAL_SPI_DMAStop()
stm32f4xx_hal_spi.h:686HAL_SPI_Abort()::hspiHAL_SPI_Abort()
stm32f4xx_hal_spi.h:687HAL_SPI_Abort_IT()::hspiHAL_SPI_Abort_IT()
stm32f4xx_hal_spi.h:689HAL_SPI_IRQHandler()::hspiHAL_SPI_IRQHandler()
stm32f4xx_hal_spi.h:690HAL_SPI_TxCpltCallback()::hspiHAL_SPI_TxCpltCallback()
stm32f4xx_hal_spi.h:691HAL_SPI_RxCpltCallback()::hspiHAL_SPI_RxCpltCallback()
stm32f4xx_hal_spi.h:692HAL_SPI_TxRxCpltCallback()::hspiHAL_SPI_TxRxCpltCallback()
stm32f4xx_hal_spi.h:693HAL_SPI_TxHalfCpltCallback()::hspiHAL_SPI_TxHalfCpltCallback()
stm32f4xx_hal_spi.h:694HAL_SPI_RxHalfCpltCallback()::hspiHAL_SPI_RxHalfCpltCallback()
stm32f4xx_hal_spi.h:695HAL_SPI_TxRxHalfCpltCallback()::hspiHAL_SPI_TxRxHalfCpltCallback()
stm32f4xx_hal_spi.h:696HAL_SPI_ErrorCallback()::hspiHAL_SPI_ErrorCallback()
stm32f4xx_hal_spi.h:697HAL_SPI_AbortCpltCallback()::hspiHAL_SPI_AbortCpltCallback()
stm32f4xx_hal_spi.h:706HAL_SPI_GetState()::hspiHAL_SPI_GetState()
stm32f4xx_hal_spi.h:707HAL_SPI_GetError()::hspiHAL_SPI_GetError()

Type Use

Variables of __SPI_HandleTypeDef type
__SPI_HandleTypeDef::RxISR::hspi
__SPI_HandleTypeDef::TxISR::hspi
SPI_DMATransmitCplt()::hspi
SPI_DMAReceiveCplt()::hspi
SPI_DMATransmitReceiveCplt()::hspi
SPI_DMAHalfTransmitCplt()::hspi
SPI_DMAHalfReceiveCplt()::hspi
SPI_DMAHalfTransmitReceiveCplt()::hspi
SPI_DMAError()::hspi
SPI_DMAAbortOnError()::hspi
SPI_DMATxAbortCallback()::hspi
SPI_DMARxAbortCallback()::hspi
all items filtered out
__SPI_HandleTypeDef
all items filtered out
__SPI_HandleTypeDef
all items filtered out