InES Hardware Abstraction Layer
|
Interface of module hal_dma. More...
Go to the source code of this file.
Data Structures | |
struct | hal_dma_init_t |
Initialization structure for direct memory access. More... | |
Enumerations | |
enum | hal_dma_stream_t { HAL_DMA_STREAM_0 = 0u, HAL_DMA_STREAM_1 = 1u, HAL_DMA_STREAM_2 = 2u, HAL_DMA_STREAM_3 = 3u, HAL_DMA_STREAM_4 = 4u, HAL_DMA_STREAM_5 = 5u, HAL_DMA_STREAM_6 = 6u, HAL_DMA_STREAM_7 = 7u } |
Defines the available streams of the dma, refer to manual p.304ff. | |
enum | hal_dma_channel_t { HAL_DMA_CHANNEL_0 = 0u, HAL_DMA_CHANNEL_1 = 1u, HAL_DMA_CHANNEL_2 = 2u, HAL_DMA_CHANNEL_3 = 3u, HAL_DMA_CHANNEL_4 = 4u, HAL_DMA_CHANNEL_5 = 5u, HAL_DMA_CHANNEL_6 = 6u, HAL_DMA_CHANNEL_7 = 7u } |
Defines the available channels of each stream, refer to manual p.304ff. | |
enum | hal_dma_dir_t { HAL_DMA_PER_TO_MEM = 0x0, HAL_DMA_MEM_TO_PER = 0x1, HAL_DMA_MEM_TO_MEM = 0x2 } |
Defines the possible directions of the transfer, refer to manual p.306ff. | |
enum | hal_dma_size_t { HAL_DMA_SIZE_8B = 0x0, HAL_DMA_SIZE_16B = 0x1, HAL_DMA_SIZE_32B = 0x2 } |
Specifies the size of the register / data. | |
Functions | |
void | hal_dma_reset (reg_dma_t *dma, hal_dma_stream_t stream) __attribute__((deprecated("Please use DMAx_RESET()."))) |
Resets the specified dma stream to its default values. More... | |
void | hal_dma_init_base (reg_dma_t *dma, hal_dma_stream_t stream, hal_dma_init_t init) |
Initializes a basic dma transfer. More... | |
void | hal_dma_start (reg_dma_t *dma, hal_dma_stream_t stream) |
Starts the dma transfer. More... | |
void | hal_dma_stop (reg_dma_t *dma, hal_dma_stream_t stream) |
Starts the dma transfer. More... | |
Interface of module hal_dma.
The hardware abstraction layer for direct memory access.
void hal_dma_init_base | ( | reg_dma_t * | dma, |
hal_dma_stream_t | stream, | ||
hal_dma_init_t | init | ||
) |
Initializes a basic dma transfer.
dma | : Defines the dma controller to initialize. |
stream | : Defines the dma stream to initialize. |
init | : Initialisation structure for dma transfer. |
void hal_dma_reset | ( | reg_dma_t * | dma, |
hal_dma_stream_t | stream | ||
) |
Resets the specified dma stream to its default values.
dma | : Defines dma controller to interact with. |
stream | : Defines stream to reset. |
void hal_dma_start | ( | reg_dma_t * | dma, |
hal_dma_stream_t | stream | ||
) |
Starts the dma transfer.
dma | : Defines dma controller to interact with. |
stream | : Defines stream to start. |
void hal_dma_stop | ( | reg_dma_t * | dma, |
hal_dma_stream_t | stream | ||
) |
Starts the dma transfer.
dma | : Defines dma controller to interact with. |
stream | : Defines stream to stop. |