Go to the documentation of this file.
21 #ifndef __STM32F7xx_HAL_SAI_H
22 #define __STM32F7xx_HAL_SAI_H
221 #if (USE_HAL_SAI_REGISTER_CALLBACKS == 1)
235 #if (USE_HAL_SAI_REGISTER_CALLBACKS == 1)
241 HAL_SAI_RX_COMPLETE_CB_ID = 0x00U,
242 HAL_SAI_RX_HALFCOMPLETE_CB_ID = 0x01U,
243 HAL_SAI_TX_COMPLETE_CB_ID = 0x02U,
244 HAL_SAI_TX_HALFCOMPLETE_CB_ID = 0x03U,
245 HAL_SAI_ERROR_CB_ID = 0x04U,
246 HAL_SAI_MSPINIT_CB_ID = 0x05U,
247 HAL_SAI_MSPDEINIT_CB_ID = 0x06U
248 } HAL_SAI_CallbackIDTypeDef;
269 #define HAL_SAI_ERROR_NONE ((uint32_t)0x00000000U)
270 #define HAL_SAI_ERROR_OVR ((uint32_t)0x00000001U)
271 #define HAL_SAI_ERROR_UDR ((uint32_t)0x00000002U)
272 #define HAL_SAI_ERROR_AFSDET ((uint32_t)0x00000004U)
273 #define HAL_SAI_ERROR_LFSDET ((uint32_t)0x00000008U)
274 #define HAL_SAI_ERROR_CNREADY ((uint32_t)0x00000010U)
275 #define HAL_SAI_ERROR_WCKCFG ((uint32_t)0x00000020U)
276 #define HAL_SAI_ERROR_TIMEOUT ((uint32_t)0x00000040U)
277 #define HAL_SAI_ERROR_DMA ((uint32_t)0x00000080U)
278 #if (USE_HAL_SAI_REGISTER_CALLBACKS == 1)
279 #define HAL_SAI_ERROR_INVALID_CALLBACK 0x00000100U
288 #define SAI_SYNCEXT_DISABLE 0
289 #define SAI_SYNCEXT_OUTBLOCKA_ENABLE 1
290 #define SAI_SYNCEXT_OUTBLOCKB_ENABLE 2
298 #define SAI_I2S_STANDARD 0
299 #define SAI_I2S_MSBJUSTIFIED 1
300 #define SAI_I2S_LSBJUSTIFIED 2
301 #define SAI_PCM_LONG 3
302 #define SAI_PCM_SHORT 4
310 #define SAI_PROTOCOL_DATASIZE_16BIT 0
311 #define SAI_PROTOCOL_DATASIZE_16BITEXTENDED 1
312 #define SAI_PROTOCOL_DATASIZE_24BIT 2
313 #define SAI_PROTOCOL_DATASIZE_32BIT 3
321 #define SAI_AUDIO_FREQUENCY_192K ((uint32_t)192000U)
322 #define SAI_AUDIO_FREQUENCY_96K ((uint32_t)96000U)
323 #define SAI_AUDIO_FREQUENCY_48K ((uint32_t)48000U)
324 #define SAI_AUDIO_FREQUENCY_44K ((uint32_t)44100U)
325 #define SAI_AUDIO_FREQUENCY_32K ((uint32_t)32000U)
326 #define SAI_AUDIO_FREQUENCY_22K ((uint32_t)22050U)
327 #define SAI_AUDIO_FREQUENCY_16K ((uint32_t)16000U)
328 #define SAI_AUDIO_FREQUENCY_11K ((uint32_t)11025U)
329 #define SAI_AUDIO_FREQUENCY_8K ((uint32_t)8000U)
330 #define SAI_AUDIO_FREQUENCY_MCKDIV ((uint32_t)0U)
338 #define SAI_MODEMASTER_TX ((uint32_t)0x00000000U)
339 #define SAI_MODEMASTER_RX ((uint32_t)SAI_xCR1_MODE_0)
340 #define SAI_MODESLAVE_TX ((uint32_t)SAI_xCR1_MODE_1)
341 #define SAI_MODESLAVE_RX ((uint32_t)(SAI_xCR1_MODE_1 | SAI_xCR1_MODE_0))
350 #define SAI_FREE_PROTOCOL ((uint32_t)0x00000000U)
351 #define SAI_SPDIF_PROTOCOL ((uint32_t)SAI_xCR1_PRTCFG_0)
352 #define SAI_AC97_PROTOCOL ((uint32_t)SAI_xCR1_PRTCFG_1)
360 #define SAI_DATASIZE_8 ((uint32_t)SAI_xCR1_DS_1)
361 #define SAI_DATASIZE_10 ((uint32_t)(SAI_xCR1_DS_1 | SAI_xCR1_DS_0))
362 #define SAI_DATASIZE_16 ((uint32_t)SAI_xCR1_DS_2)
363 #define SAI_DATASIZE_20 ((uint32_t)(SAI_xCR1_DS_2 | SAI_xCR1_DS_0))
364 #define SAI_DATASIZE_24 ((uint32_t)(SAI_xCR1_DS_2 | SAI_xCR1_DS_1))
365 #define SAI_DATASIZE_32 ((uint32_t)(SAI_xCR1_DS_2 | SAI_xCR1_DS_1 | SAI_xCR1_DS_0))
373 #define SAI_FIRSTBIT_MSB ((uint32_t)0x00000000U)
374 #define SAI_FIRSTBIT_LSB ((uint32_t)SAI_xCR1_LSBFIRST)
382 #define SAI_CLOCKSTROBING_FALLINGEDGE 0
383 #define SAI_CLOCKSTROBING_RISINGEDGE 1
391 #define SAI_ASYNCHRONOUS 0
392 #define SAI_SYNCHRONOUS 1
393 #define SAI_SYNCHRONOUS_EXT_SAI1 2
394 #define SAI_SYNCHRONOUS_EXT_SAI2 3
402 #define SAI_OUTPUTDRIVE_DISABLE ((uint32_t)0x00000000U)
403 #define SAI_OUTPUTDRIVE_ENABLE ((uint32_t)SAI_xCR1_OUTDRIV)
411 #define SAI_MASTERDIVIDER_ENABLE ((uint32_t)0x00000000U)
412 #define SAI_MASTERDIVIDER_DISABLE ((uint32_t)SAI_xCR1_NODIV)
420 #define SAI_FS_STARTFRAME ((uint32_t)0x00000000U)
421 #define SAI_FS_CHANNEL_IDENTIFICATION ((uint32_t)SAI_xFRCR_FSDEF)
429 #define SAI_FS_ACTIVE_LOW ((uint32_t)0x00000000U)
430 #define SAI_FS_ACTIVE_HIGH ((uint32_t)SAI_xFRCR_FSPOL)
438 #define SAI_FS_FIRSTBIT ((uint32_t)0x00000000U)
439 #define SAI_FS_BEFOREFIRSTBIT ((uint32_t)SAI_xFRCR_FSOFF)
447 #define SAI_SLOTSIZE_DATASIZE ((uint32_t)0x00000000U)
448 #define SAI_SLOTSIZE_16B ((uint32_t)SAI_xSLOTR_SLOTSZ_0)
449 #define SAI_SLOTSIZE_32B ((uint32_t)SAI_xSLOTR_SLOTSZ_1)
457 #define SAI_SLOT_NOTACTIVE ((uint32_t)0x00000000U)
458 #define SAI_SLOTACTIVE_0 ((uint32_t)0x00000001U)
459 #define SAI_SLOTACTIVE_1 ((uint32_t)0x00000002U)
460 #define SAI_SLOTACTIVE_2 ((uint32_t)0x00000004U)
461 #define SAI_SLOTACTIVE_3 ((uint32_t)0x00000008U)
462 #define SAI_SLOTACTIVE_4 ((uint32_t)0x00000010U)
463 #define SAI_SLOTACTIVE_5 ((uint32_t)0x00000020U)
464 #define SAI_SLOTACTIVE_6 ((uint32_t)0x00000040U)
465 #define SAI_SLOTACTIVE_7 ((uint32_t)0x00000080U)
466 #define SAI_SLOTACTIVE_8 ((uint32_t)0x00000100U)
467 #define SAI_SLOTACTIVE_9 ((uint32_t)0x00000200U)
468 #define SAI_SLOTACTIVE_10 ((uint32_t)0x00000400U)
469 #define SAI_SLOTACTIVE_11 ((uint32_t)0x00000800U)
470 #define SAI_SLOTACTIVE_12 ((uint32_t)0x00001000U)
471 #define SAI_SLOTACTIVE_13 ((uint32_t)0x00002000U)
472 #define SAI_SLOTACTIVE_14 ((uint32_t)0x00004000U)
473 #define SAI_SLOTACTIVE_15 ((uint32_t)0x00008000U)
474 #define SAI_SLOTACTIVE_ALL ((uint32_t)0x0000FFFFU)
482 #define SAI_STEREOMODE ((uint32_t)0x00000000U)
483 #define SAI_MONOMODE ((uint32_t)SAI_xCR1_MONO)
491 #define SAI_OUTPUT_NOTRELEASED ((uint32_t)0x00000000U)
492 #define SAI_OUTPUT_RELEASED ((uint32_t)SAI_xCR2_TRIS)
500 #define SAI_FIFOTHRESHOLD_EMPTY ((uint32_t)0x00000000U)
501 #define SAI_FIFOTHRESHOLD_1QF ((uint32_t)(SAI_xCR2_FTH_0))
502 #define SAI_FIFOTHRESHOLD_HF ((uint32_t)(SAI_xCR2_FTH_1))
503 #define SAI_FIFOTHRESHOLD_3QF ((uint32_t)(SAI_xCR2_FTH_1 | SAI_xCR2_FTH_0))
504 #define SAI_FIFOTHRESHOLD_FULL ((uint32_t)(SAI_xCR2_FTH_2))
512 #define SAI_NOCOMPANDING ((uint32_t)0x00000000U)
513 #define SAI_ULAW_1CPL_COMPANDING ((uint32_t)(SAI_xCR2_COMP_1))
514 #define SAI_ALAW_1CPL_COMPANDING ((uint32_t)(SAI_xCR2_COMP_1 | SAI_xCR2_COMP_0))
515 #define SAI_ULAW_2CPL_COMPANDING ((uint32_t)(SAI_xCR2_COMP_1 | SAI_xCR2_CPL))
516 #define SAI_ALAW_2CPL_COMPANDING ((uint32_t)(SAI_xCR2_COMP_1 | SAI_xCR2_COMP_0 | SAI_xCR2_CPL))
524 #define SAI_ZERO_VALUE ((uint32_t)0x00000000U)
525 #define SAI_LAST_SENT_VALUE ((uint32_t)SAI_xCR2_MUTEVAL)
533 #define SAI_IT_OVRUDR ((uint32_t)SAI_xIMR_OVRUDRIE)
534 #define SAI_IT_MUTEDET ((uint32_t)SAI_xIMR_MUTEDETIE)
535 #define SAI_IT_WCKCFG ((uint32_t)SAI_xIMR_WCKCFGIE)
536 #define SAI_IT_FREQ ((uint32_t)SAI_xIMR_FREQIE)
537 #define SAI_IT_CNRDY ((uint32_t)SAI_xIMR_CNRDYIE)
538 #define SAI_IT_AFSDET ((uint32_t)SAI_xIMR_AFSDETIE)
539 #define SAI_IT_LFSDET ((uint32_t)SAI_xIMR_LFSDETIE)
547 #define SAI_FLAG_OVRUDR ((uint32_t)SAI_xSR_OVRUDR)
548 #define SAI_FLAG_MUTEDET ((uint32_t)SAI_xSR_MUTEDET)
549 #define SAI_FLAG_WCKCFG ((uint32_t)SAI_xSR_WCKCFG)
550 #define SAI_FLAG_FREQ ((uint32_t)SAI_xSR_FREQ)
551 #define SAI_FLAG_CNRDY ((uint32_t)SAI_xSR_CNRDY)
552 #define SAI_FLAG_AFSDET ((uint32_t)SAI_xSR_AFSDET)
553 #define SAI_FLAG_LFSDET ((uint32_t)SAI_xSR_LFSDET)
561 #define SAI_FIFOSTATUS_EMPTY ((uint32_t)0x00000000U)
562 #define SAI_FIFOSTATUS_LESS1QUARTERFULL ((uint32_t)0x00010000U)
563 #define SAI_FIFOSTATUS_1QUARTERFULL ((uint32_t)0x00020000U)
564 #define SAI_FIFOSTATUS_HALFFULL ((uint32_t)0x00030000U)
565 #define SAI_FIFOSTATUS_3QUARTERFULL ((uint32_t)0x00040000U)
566 #define SAI_FIFOSTATUS_FULL ((uint32_t)0x00050000U)
585 #if (USE_HAL_SAI_REGISTER_CALLBACKS == 1)
586 #define __HAL_SAI_RESET_HANDLE_STATE(__HANDLE__) do{ \
587 (__HANDLE__)->State = HAL_SAI_STATE_RESET; \
588 (__HANDLE__)->MspInitCallback = NULL; \
589 (__HANDLE__)->MspDeInitCallback = NULL; \
592 #define __HAL_SAI_RESET_HANDLE_STATE(__HANDLE__) ((__HANDLE__)->State = HAL_SAI_STATE_RESET)
608 #define __HAL_SAI_ENABLE_IT(__HANDLE__, __INTERRUPT__) ((__HANDLE__)->Instance->IMR |= (__INTERRUPT__))
609 #define __HAL_SAI_DISABLE_IT(__HANDLE__, __INTERRUPT__) ((__HANDLE__)->Instance->IMR &= (~(__INTERRUPT__)))
624 #define __HAL_SAI_GET_IT_SOURCE(__HANDLE__, __INTERRUPT__) ((((__HANDLE__)->Instance->IMR & (__INTERRUPT__)) == (__INTERRUPT__)) ? SET : RESET)
639 #define __HAL_SAI_GET_FLAG(__HANDLE__, __FLAG__) ((((__HANDLE__)->Instance->SR) & (__FLAG__)) == (__FLAG__))
655 #define __HAL_SAI_CLEAR_FLAG(__HANDLE__, __FLAG__) ((__HANDLE__)->Instance->CLRFR = (__FLAG__))
657 #define __HAL_SAI_ENABLE(__HANDLE__) ((__HANDLE__)->Instance->CR1 |= SAI_xCR1_SAIEN)
658 #define __HAL_SAI_DISABLE(__HANDLE__) ((__HANDLE__)->Instance->CR1 &= ~SAI_xCR1_SAIEN)
679 #if (USE_HAL_SAI_REGISTER_CALLBACKS == 1)
682 HAL_SAI_CallbackIDTypeDef CallbackID,
683 pSAI_CallbackTypeDef pCallback);
685 HAL_SAI_CallbackIDTypeDef CallbackID);
749 #define IS_SAI_BLOCK_SYNCEXT(STATE) (((STATE) == SAI_SYNCEXT_DISABLE) ||\
750 ((STATE) == SAI_SYNCEXT_OUTBLOCKA_ENABLE) ||\
751 ((STATE) == SAI_SYNCEXT_OUTBLOCKB_ENABLE))
753 #define IS_SAI_SUPPORTED_PROTOCOL(PROTOCOL) (((PROTOCOL) == SAI_I2S_STANDARD) ||\
754 ((PROTOCOL) == SAI_I2S_MSBJUSTIFIED) ||\
755 ((PROTOCOL) == SAI_I2S_LSBJUSTIFIED) ||\
756 ((PROTOCOL) == SAI_PCM_LONG) ||\
757 ((PROTOCOL) == SAI_PCM_SHORT))
759 #define IS_SAI_PROTOCOL_DATASIZE(DATASIZE) (((DATASIZE) == SAI_PROTOCOL_DATASIZE_16BIT) ||\
760 ((DATASIZE) == SAI_PROTOCOL_DATASIZE_16BITEXTENDED) ||\
761 ((DATASIZE) == SAI_PROTOCOL_DATASIZE_24BIT) ||\
762 ((DATASIZE) == SAI_PROTOCOL_DATASIZE_32BIT))
764 #define IS_SAI_AUDIO_FREQUENCY(AUDIO) (((AUDIO) == SAI_AUDIO_FREQUENCY_192K) || ((AUDIO) == SAI_AUDIO_FREQUENCY_96K) || \
765 ((AUDIO) == SAI_AUDIO_FREQUENCY_48K) || ((AUDIO) == SAI_AUDIO_FREQUENCY_44K) || \
766 ((AUDIO) == SAI_AUDIO_FREQUENCY_32K) || ((AUDIO) == SAI_AUDIO_FREQUENCY_22K) || \
767 ((AUDIO) == SAI_AUDIO_FREQUENCY_16K) || ((AUDIO) == SAI_AUDIO_FREQUENCY_11K) || \
768 ((AUDIO) == SAI_AUDIO_FREQUENCY_8K) || ((AUDIO) == SAI_AUDIO_FREQUENCY_MCKDIV))
770 #define IS_SAI_BLOCK_MODE(MODE) (((MODE) == SAI_MODEMASTER_TX) || \
771 ((MODE) == SAI_MODEMASTER_RX) || \
772 ((MODE) == SAI_MODESLAVE_TX) || \
773 ((MODE) == SAI_MODESLAVE_RX))
775 #define IS_SAI_BLOCK_PROTOCOL(PROTOCOL) (((PROTOCOL) == SAI_FREE_PROTOCOL) || \
776 ((PROTOCOL) == SAI_AC97_PROTOCOL) || \
777 ((PROTOCOL) == SAI_SPDIF_PROTOCOL))
779 #define IS_SAI_BLOCK_DATASIZE(DATASIZE) (((DATASIZE) == SAI_DATASIZE_8) || \
780 ((DATASIZE) == SAI_DATASIZE_10) || \
781 ((DATASIZE) == SAI_DATASIZE_16) || \
782 ((DATASIZE) == SAI_DATASIZE_20) || \
783 ((DATASIZE) == SAI_DATASIZE_24) || \
784 ((DATASIZE) == SAI_DATASIZE_32))
786 #define IS_SAI_BLOCK_FIRST_BIT(BIT) (((BIT) == SAI_FIRSTBIT_MSB) || \
787 ((BIT) == SAI_FIRSTBIT_LSB))
789 #define IS_SAI_BLOCK_CLOCK_STROBING(CLOCK) (((CLOCK) == SAI_CLOCKSTROBING_FALLINGEDGE) || \
790 ((CLOCK) == SAI_CLOCKSTROBING_RISINGEDGE))
792 #define IS_SAI_BLOCK_SYNCHRO(SYNCHRO) (((SYNCHRO) == SAI_ASYNCHRONOUS) || \
793 ((SYNCHRO) == SAI_SYNCHRONOUS) || \
794 ((SYNCHRO) == SAI_SYNCHRONOUS_EXT_SAI1) || \
795 ((SYNCHRO) == SAI_SYNCHRONOUS_EXT_SAI2))
797 #define IS_SAI_BLOCK_OUTPUT_DRIVE(DRIVE) (((DRIVE) == SAI_OUTPUTDRIVE_DISABLE) || \
798 ((DRIVE) == SAI_OUTPUTDRIVE_ENABLE))
800 #define IS_SAI_BLOCK_NODIVIDER(NODIVIDER) (((NODIVIDER) == SAI_MASTERDIVIDER_ENABLE) || \
801 ((NODIVIDER) == SAI_MASTERDIVIDER_DISABLE))
803 #define IS_SAI_BLOCK_MUTE_COUNTER(COUNTER) ((COUNTER) <= 63)
805 #define IS_SAI_BLOCK_MUTE_VALUE(VALUE) (((VALUE) == SAI_ZERO_VALUE) || \
806 ((VALUE) == SAI_LAST_SENT_VALUE))
808 #define IS_SAI_BLOCK_COMPANDING_MODE(MODE) (((MODE) == SAI_NOCOMPANDING) || \
809 ((MODE) == SAI_ULAW_1CPL_COMPANDING) || \
810 ((MODE) == SAI_ALAW_1CPL_COMPANDING) || \
811 ((MODE) == SAI_ULAW_2CPL_COMPANDING) || \
812 ((MODE) == SAI_ALAW_2CPL_COMPANDING))
814 #define IS_SAI_BLOCK_FIFO_THRESHOLD(THRESHOLD) (((THRESHOLD) == SAI_FIFOTHRESHOLD_EMPTY) || \
815 ((THRESHOLD) == SAI_FIFOTHRESHOLD_1QF) || \
816 ((THRESHOLD) == SAI_FIFOTHRESHOLD_HF) || \
817 ((THRESHOLD) == SAI_FIFOTHRESHOLD_3QF) || \
818 ((THRESHOLD) == SAI_FIFOTHRESHOLD_FULL))
820 #define IS_SAI_BLOCK_TRISTATE_MANAGEMENT(STATE) (((STATE) == SAI_OUTPUT_NOTRELEASED) ||\
821 ((STATE) == SAI_OUTPUT_RELEASED))
823 #define IS_SAI_MONO_STEREO_MODE(MODE) (((MODE) == SAI_MONOMODE) ||\
824 ((MODE) == SAI_STEREOMODE))
826 #define IS_SAI_SLOT_ACTIVE(ACTIVE) ((ACTIVE) <= SAI_SLOTACTIVE_ALL)
828 #define IS_SAI_BLOCK_SLOT_NUMBER(NUMBER) ((1 <= (NUMBER)) && ((NUMBER) <= 16))
830 #define IS_SAI_BLOCK_SLOT_SIZE(SIZE) (((SIZE) == SAI_SLOTSIZE_DATASIZE) || \
831 ((SIZE) == SAI_SLOTSIZE_16B) || \
832 ((SIZE) == SAI_SLOTSIZE_32B))
834 #define IS_SAI_BLOCK_FIRSTBIT_OFFSET(OFFSET) ((OFFSET) <= 24)
836 #define IS_SAI_BLOCK_FS_OFFSET(OFFSET) (((OFFSET) == SAI_FS_FIRSTBIT) || \
837 ((OFFSET) == SAI_FS_BEFOREFIRSTBIT))
839 #define IS_SAI_BLOCK_FS_POLARITY(POLARITY) (((POLARITY) == SAI_FS_ACTIVE_LOW) || \
840 ((POLARITY) == SAI_FS_ACTIVE_HIGH))
842 #define IS_SAI_BLOCK_FS_DEFINITION(DEFINITION) (((DEFINITION) == SAI_FS_STARTFRAME) || \
843 ((DEFINITION) == SAI_FS_CHANNEL_IDENTIFICATION))
845 #define IS_SAI_BLOCK_MASTER_DIVIDER(DIVIDER) ((DIVIDER) <= 15U)
847 #define IS_SAI_BLOCK_FRAME_LENGTH(LENGTH) ((8 <= (LENGTH)) && ((LENGTH) <= 256))
849 #define IS_SAI_BLOCK_ACTIVE_FRAME(LENGTH) ((1 <= (LENGTH)) && ((LENGTH) <= 128))
HAL_StatusTypeDef HAL_SAI_DisableRxMuteMode(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_DisableTxMuteMode(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef
HAL Status structures definition
void HAL_SAI_MspInit(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_DMAStop(SAI_HandleTypeDef *hsai)
uint32_t ActiveFrameLength
DMA handle Structure definition.
DMA_HandleTypeDef * hdmatx
HAL_StatusTypeDef HAL_SAI_DMAPause(SAI_HandleTypeDef *hsai)
void HAL_SAI_RxHalfCpltCallback(SAI_HandleTypeDef *hsai)
Half reception complete callback.
struct __SAI_HandleTypeDef SAI_HandleTypeDef
void HAL_SAI_TxCpltCallback(SAI_HandleTypeDef *hsai)
Tx Transfer completed callbacks.
HAL_StatusTypeDef HAL_SAI_DeInit(SAI_HandleTypeDef *hsai)
HAL_SAI_StateTypeDef HAL_SAI_GetState(SAI_HandleTypeDef *hsai)
__IO HAL_SAI_StateTypeDef State
HAL_StatusTypeDef HAL_SAI_Receive(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size, uint32_t Timeout)
HAL_LockTypeDef
HAL Lock structures definition
void HAL_SAI_IRQHandler(SAI_HandleTypeDef *hsai)
DMA_HandleTypeDef * hdmarx
void HAL_SAI_ErrorCallback(SAI_HandleTypeDef *hsai)
SAI error callbacks.
SAI_Block_TypeDef * Instance
HAL_StatusTypeDef HAL_SAI_InitProtocol(SAI_HandleTypeDef *hsai, uint32_t protocol, uint32_t datasize, uint32_t nbslot)
uint32_t HAL_SAI_GetError(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_DMAResume(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_Transmit_IT(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size)
HAL_StatusTypeDef HAL_SAI_EnableTxMuteMode(SAI_HandleTypeDef *hsai, uint16_t val)
void HAL_SAI_RxCpltCallback(SAI_HandleTypeDef *hsai)
Reception complete callback.
void(* InterruptServiceRoutine)(struct __SAI_HandleTypeDef *hsai)
void HAL_SAI_TxHalfCpltCallback(SAI_HandleTypeDef *hsai)
Tx Half Transfer completed callbacks.
HAL_StatusTypeDef HAL_SAI_Transmit(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size, uint32_t Timeout)
HAL_StatusTypeDef HAL_SAI_Receive_DMA(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size)
This file contains HAL common defines, enumeration, macros and structures definitions.
HAL_SAI_StateTypeDef
HAL State structures definition.
HAL_StatusTypeDef HAL_SAI_Init(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_Receive_IT(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size)
void(* SAIcallback)(void)
SAI Callback prototype.
void HAL_SAI_MspDeInit(SAI_HandleTypeDef *hsai)
HAL_StatusTypeDef HAL_SAI_Abort(SAI_HandleTypeDef *hsai)
SAI_SlotInitTypeDef SlotInit
SAI_FrameInitTypeDef FrameInit
HAL_StatusTypeDef HAL_SAI_Transmit_DMA(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size)
HAL_StatusTypeDef HAL_SAI_EnableRxMuteMode(SAI_HandleTypeDef *hsai, SAIcallback callback, uint16_t counter)