Callback structure that can be used to define DMA complete actions.

A reference to this structure is only stored in the primary descriptor for a channel (if using callback feature). If callback is required for both primary and alternate descriptor completion, this must be handled by one common callback, using the provided 'primary' parameter with the callback function.

Public Attributes#

Pointer to callback function to invoke when DMA transfer cycle is done.

void *

User defined pointer to provide with callback function.

uint8_t

For internal use only: Indicates if next callback applies to primary or alternate descriptor completion.

Public Attribute Documentation#

cbFunc#

DMA_FuncPtr_TypeDef DMA_CB_TypeDef::cbFunc

Pointer to callback function to invoke when DMA transfer cycle is done.

Notice that this function is invoked in interrupt context, and therefore should be short and non-blocking.


Definition at line 138 of file platform/emlib/inc/em_dma.h

userPtr#

void* DMA_CB_TypeDef::userPtr

User defined pointer to provide with callback function.


Definition at line 141 of file platform/emlib/inc/em_dma.h

primary#

uint8_t DMA_CB_TypeDef::primary

For internal use only: Indicates if next callback applies to primary or alternate descriptor completion.

Mainly useful for ping-pong DMA cycles. Set this value to 0 prior to configuring callback handling.


Definition at line 148 of file platform/emlib/inc/em_dma.h