Functions

uint16_t app_dspi_init (app_dspi_params_t *p_params, app_dspi_evt_handler_t evt_handler)
 Initialize the APP DSPI DRIVER according to the specified parameters in the app_dspi_params_t and app_dspi_evt_handler_t. More...
 
uint16_t app_dspi_deinit (void)
 De-initialize the APP DSPI DRIVER peripheral. More...
 
uint16_t app_dspi_command_transmit_sync (app_dspi_command_t *p_cmd, uint8_t *p_data, uint32_t timeout)
 Receive an amount of data with the specified instruction in blocking mode. More...
 
uint16_t app_dspi_command_transmit_async (app_dspi_command_t *p_cmd, uint8_t *p_data)
 Receive an amount of data with the specified instruction in non-blocking mode with Interrupt. More...
 
uint16_t app_dspi_command_sync (app_dspi_command_t *p_cmd, uint32_t timeout)
 Transmit only instruction in blocking mode. More...
 
uint16_t app_dspi_command_async (app_dspi_command_t *p_cmd)
 Transmit instruction in non-blocking mode with Interrupt. More...
 
uint16_t app_dspi_transmit_sync (uint8_t *p_data, uint32_t length, uint32_t timeout)
 Transmit an amount of data in blocking mode. More...
 
uint16_t app_dspi_transmit_async (uint8_t *p_data, uint32_t length)
 Transmit an amount of data in non-blocking mode with Interrupt. More...
 
dspi_handle_tapp_dspi_get_handle (void)
 Return the DSPI handle. More...
 
uint16_t app_dspi_config_mode (uint32_t mode)
 Set the DSPI transmission mode. More...
 
uint16_t app_dspi_config_data_size (uint32_t data_size)
 Set the DSPI transmission data size. More...
 
uint16_t app_dspi_abort (void)
 Abort the current transmission. More...
 
uint16_t app_dspi_abort_it (void)
 Abort the current transmission (non-blocking function) More...
 
uint16_t app_dspi_dma_init (app_dspi_params_t *p_params)
 Initialize the APP DSPI DRIVER according to the specified parameters in the app_dspi_params_t and app_dspi_evt_handler_t. More...
 
uint16_t app_dspi_dma_deinit (void)
 De-initialize the APP DSPI DRIVER peripheral. More...
 
uint16_t app_dspi_dma_command_transmit_async (app_dspi_command_t *p_cmd, uint8_t *p_data)
 Receive an amount of data with the specified instruction in non-blocking mode with Interrupt. More...
 
uint16_t app_dspi_dma_command_async (app_dspi_command_t *p_cmd)
 Transmit instruction in non-blocking mode with Interrupt. More...
 
uint16_t app_dspi_dma_transmit_async (uint8_t *p_data, uint32_t length)
 Transmit an amount of data in non-blocking mode with DMA. More...
 
uint16_t app_dspi_dma_sg_llp_transmit_async (uint8_t *p_data, uint32_t length, dma_sg_llp_config_t *sg_llp_config)
 Transmit an amount of data in non-blocking mode with DMA SG or LLP. More...
 

Detailed Description

Function Documentation

◆ app_dspi_abort()

uint16_t app_dspi_abort ( void  )

Abort the current transmission.

Returns
Result of operation.

◆ app_dspi_abort_it()

uint16_t app_dspi_abort_it ( void  )

Abort the current transmission (non-blocking function)

Returns
Result of operation.

◆ app_dspi_command_async()

uint16_t app_dspi_command_async ( app_dspi_command_t p_cmd)

Transmit instruction in non-blocking mode with Interrupt.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction for data transfer.
Returns
Result of operation.

◆ app_dspi_command_sync()

uint16_t app_dspi_command_sync ( app_dspi_command_t p_cmd,
uint32_t  timeout 
)

Transmit only instruction in blocking mode.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction for data transfer.
[in]timeoutTimeout duration
Returns
Result of operation.

◆ app_dspi_command_transmit_async()

uint16_t app_dspi_command_transmit_async ( app_dspi_command_t p_cmd,
uint8_t *  p_data 
)

Receive an amount of data with the specified instruction in non-blocking mode with Interrupt.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction, length, data_size for data transfer.
[out]p_dataPointer to data buffer
Returns
Result of operation.

◆ app_dspi_command_transmit_sync()

uint16_t app_dspi_command_transmit_sync ( app_dspi_command_t p_cmd,
uint8_t *  p_data,
uint32_t  timeout 
)

Receive an amount of data with the specified instruction in blocking mode.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction, length, data_size for data transfer.
[out]p_dataPointer to data buffer
[in]timeoutTimeout duration
Returns
Result of operation.

◆ app_dspi_config_data_size()

◆ app_dspi_config_mode()

uint16_t app_dspi_config_mode ( uint32_t  mode)

Set the DSPI transmission mode.

Parameters
[in]modethe DSPI transmission mode.This parameter can be one of the following values:
Returns
Result of operation.

◆ app_dspi_deinit()

uint16_t app_dspi_deinit ( void  )

De-initialize the APP DSPI DRIVER peripheral.

Returns
Result of De-initialization.

◆ app_dspi_dma_command_async()

uint16_t app_dspi_dma_command_async ( app_dspi_command_t p_cmd)

Transmit instruction in non-blocking mode with Interrupt.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction for data transfer.
Returns
Result of operation.

◆ app_dspi_dma_command_transmit_async()

uint16_t app_dspi_dma_command_transmit_async ( app_dspi_command_t p_cmd,
uint8_t *  p_data 
)

Receive an amount of data with the specified instruction in non-blocking mode with Interrupt.

Parameters
[in]p_cmdPointer to a app_dspi_command_t structure that contains the instruction, length, data_size for data transfer.
[out]p_dataPointer to data buffer
Returns
Result of operation.

◆ app_dspi_dma_deinit()

uint16_t app_dspi_dma_deinit ( void  )

De-initialize the APP DSPI DRIVER peripheral.

Returns
Result of De-initialization.

◆ app_dspi_dma_init()

uint16_t app_dspi_dma_init ( app_dspi_params_t p_params)

Initialize the APP DSPI DRIVER according to the specified parameters in the app_dspi_params_t and app_dspi_evt_handler_t.

Note
If interrupt mode is set, you can use blocking mode. Conversely, if blocking mode is set, you can't use interrupt mode.
Parameters
[in]p_paramsPointer to app_dspi_params_t parameter which contains the configuration information for the specified DSPI module.
Returns
Result of initialization.

◆ app_dspi_dma_sg_llp_transmit_async()

uint16_t app_dspi_dma_sg_llp_transmit_async ( uint8_t *  p_data,
uint32_t  length,
dma_sg_llp_config_t sg_llp_config 
)

Transmit an amount of data in non-blocking mode with DMA SG or LLP.

Parameters
[in]p_dataPointer to data buffer
[in]lengthAmount of data to be sent in bytes, ranging between 0 and 4095.
[in]sg_llp_configThe config of source and destination's SG and LLP.
Returns
Result of operation.

◆ app_dspi_dma_transmit_async()

uint16_t app_dspi_dma_transmit_async ( uint8_t *  p_data,
uint32_t  length 
)

Transmit an amount of data in non-blocking mode with DMA.

Parameters
[in]p_dataPointer to data buffer
[in]lengthAmount of data to be sent in bytes, ranging between 0 and 4095.
Returns
Result of operation.

◆ app_dspi_get_handle()

dspi_handle_t* app_dspi_get_handle ( void  )

Return the DSPI handle.

Returns
Pointer to the DSPI handle.

◆ app_dspi_init()

uint16_t app_dspi_init ( app_dspi_params_t p_params,
app_dspi_evt_handler_t  evt_handler 
)

Initialize the APP DSPI DRIVER according to the specified parameters in the app_dspi_params_t and app_dspi_evt_handler_t.

Note
If interrupt mode is set, you can use blocking mode. Conversely, if blocking mode is set, you can't use interrupt mode.
Parameters
[in]p_paramsPointer to app_dspi_params_t parameter which contains the configuration information for the specified DSPI module.
[in]evt_handlerDSPI user callback function.
Returns
Result of initialization.

◆ app_dspi_transmit_async()

uint16_t app_dspi_transmit_async ( uint8_t *  p_data,
uint32_t  length 
)

Transmit an amount of data in non-blocking mode with Interrupt.

Parameters
[in]p_dataPointer to data buffer
[in]lengthAmount of data to be sent in bytes
Returns
Result of operation.

◆ app_dspi_transmit_sync()

uint16_t app_dspi_transmit_sync ( uint8_t *  p_data,
uint32_t  length,
uint32_t  timeout 
)

Transmit an amount of data in blocking mode.

Parameters
[in]p_dataPointer to data buffer
[in]lengthAmount of data to be sent in bytes
[in]timeoutTimeout duration
Returns
Result of operation.