{/*Control if the TX fifo is empty*/if(SPI_WaitFifoStateUntilTimeout(hspi, SPI_FLAG_FTLVL, SPI_FTLVL_EMPTY, Timeout, Tickstart) !=HAL_OK) { SET_BIT(hspi->ErrorCode, HAL_SPI_ERROR_FLAG);returnHAL_TIMEOUT; }/*等待发送寄存器空,最后一个数据已经移出发送寄存器DR*//*Control the BSY...
if (SPI_FLAG_FTLVL == SPI_SR_FRLVL) { /* Read 8bit CRC to flush Data Register */ READ_REG(*((__IO uint8_t *)&hspi->Instance->DR)); } } // Control the BSY flag while (__HAL_SPI_GET_FLAG(hspi, SPI_FLAG_BSY)); // Control if the RX fifo is empty while ((hspi-...
STM32F3产品技术培训-03.SPI模块