cancel
Showing results for 
Search instead for 
Did you mean: 

What to use for HAL_SAI_Receive Size parameter?

RBamf.1
Associate III

Hi, I'm trying to work with the SAI HAL interface, i have set the black frame to 64 bits wide and the block slot size to 32B.

When using the HAL_SAI_Receive() function, what does the length parameter represent?

For my solution i am sending 2 32bit slots in 1 64 bit frame, therefore is the length parameter set to 64 bits?

Here's the SAI function in question:

/**
  * @brief  Receive an amount of data in blocking mode.
  * @param  hsai pointer to a SAI_HandleTypeDef structure that contains
  *              the configuration information for SAI module.
  * @param  pData Pointer to data buffer
  * @param  Size Amount of data to be received
  * @param  Timeout Timeout duration
  * @retval HAL status
  */
HAL_StatusTypeDef HAL_SAI_Receive(SAI_HandleTypeDef *hsai, uint8_t *pData, uint16_t Size, uint32_t Timeout)

It is found in stm32l4xx_hal_sai.c line 1133.

My setup is an Nucleo-64 STM32L452RE.

Many Thanks!

Richard

1 REPLY 1
RBamf.1
Associate III

Anyone?