Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
cubexHal.pdf
Скачиваний:
111
Добавлен:
10.02.2016
Размер:
16.16 Mб
Скачать

HAL DMA Extension Driver

UM1725

17 HAL DMA Extension Driver

17.1DMAEx Firmware driver API description

17.1.1How to use this driver

The DMA Extension HAL driver can be used as follows:

1. Start a multi buffer transfer using the HAL_DMA_MultiBufferStart() function for polling mode or HAL_DMA_MultiBufferStart_IT() for interrupt mode. In Memory-to-Memory transfer mode, Multi (Double) Buffer mode is not allowed. When Multi (Double) Buffer mode is enabled the, transfer is circular by default. In Multi (Double) buffer mode, it is possible to update the base address for the AHB memory port on the fly (DMA_SxM0AR or DMA_SxM1AR) when the stream is enabled.

17.1.2Extended features functions

This section provides functions allowing to:

Configure the source, destination address and data length and Start MultiBuffer DMA transfer

Configure the source, destination address and data length and Start MultiBuffer DMA transfer with interrupt

Change on the fly the memory0 or memory1 address.

This section contains the following APIs:

HAL_DMAEx_MultiBufferStart()

HAL_DMAEx_MultiBufferStart_IT()

HAL_DMAEx_ChangeMemory()

17.1.3HAL_DMAEx_MultiBufferStart

Function Name

HAL_StatusTypeDef HAL_DMAEx_MultiBufferStart

 

(DMA_HandleTypeDef * hdma, uint32_t SrcAddress, uint32_t

 

DstAddress, uint32_t SecondMemAddress, uint32_t

 

DataLength)

Function Description

Starts the multi_buffer DMA Transfer.

Parameters

 

hdma: : pointer to a DMA_HandleTypeDef structure that

 

 

contains the configuration information for the specified DMA

 

 

Stream.

 

SrcAddress: The source memory Buffer address

 

DstAddress: The destination memory Buffer address

 

SecondMemAddress: The second memory Buffer address

 

 

in case of multi buffer Transfer

 

DataLength: The length of data to be transferred from

 

 

source to destination

Return values

 

HAL status

17.1.4HAL_DMAEx_MultiBufferStart_IT

Function Name

HAL_StatusTypeDef HAL_DMAEx_MultiBufferStart_IT

 

(DMA_HandleTypeDef * hdma, uint32_t SrcAddress, uint32_t

246/900

DOCID025834 Rev 2

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]