4 #include <twr_common.h>
void twr_dma_channel_config(twr_dma_channel_t channel, twr_dma_channel_config_t *config)
Configure DMA channel.
void twr_dma_channel_run(twr_dma_channel_t channel)
Start DMA channel.
twr_dma_request_t
DMA requests.
void twr_dma_set_event_handler(twr_dma_channel_t channel, void(*event_handler)(twr_dma_channel_t, twr_dma_event_t, void *), void *event_param)
Set callback function.
twr_dma_event_t
DMA channel event.
twr_dma_size_t
DMA channel data size.
twr_dma_direction_t
DMA channel directions.
void twr_dma_init(void)
Initialize DMA.
twr_dma_priority_t
DMA channel priority.
twr_dma_channel_t
DMA channels.
twr_dma_mode_t
DMA channel mode.
void twr_dma_channel_stop(twr_dma_channel_t channel)
Stop DMA channel.
@ TWR_DMA_REQUEST_3
DMA request 3.
@ TWR_DMA_REQUEST_1
DMA request 1.
@ TWR_DMA_REQUEST_4
DMA request 4.
@ TWR_DMA_REQUEST_11
DMA request 11.
@ TWR_DMA_REQUEST_0
DMA request 0.
@ TWR_DMA_REQUEST_10
DMA request 10.
@ TWR_DMA_REQUEST_5
DMA request 5.
@ TWR_DMA_REQUEST_9
DMA request 9.
@ TWR_DMA_REQUEST_6
DMA request 6.
@ TWR_DMA_REQUEST_14
DMA request 14.
@ TWR_DMA_REQUEST_2
DMA request 2.
@ TWR_DMA_REQUEST_13
DMA request 13.
@ TWR_DMA_REQUEST_15
DMA request 15.
@ TWR_DMA_REQUEST_8
DMA request 8.
@ TWR_DMA_REQUEST_12
DMA request 12.
@ TWR_DMA_REQUEST_7
DMA request 7.
@ TWR_DMA_EVENT_DONE
DMA channel event done.
@ TWR_DMA_EVENT_HALF_DONE
DMA channel event half done.
@ TWR_DMA_EVENT_ERROR
DMA channel event error.
@ TWR_DMA_SIZE_2
DMA channel data size 2B.
@ TWR_DMA_SIZE_4
DMA channel data size 4B.
@ TWR_DMA_SIZE_1
DMA channel data size 1B.
@ TWR_DMA_DIRECTION_TO_PERIPHERAL
DMA channel direction from RAM to peripheral.
@ TWR_DMA_DIRECTION_TO_RAM
DMA channel direction from peripheral to RAM.
@ TWR_DMA_PRIORITY_MEDIUM
DMA channel priority is medium.
@ TWR_DMA_PRIORITY_VERY_HIGH
DMA channel priority is very high.
@ TWR_DMA_PRIORITY_HIGH
DMA channel priority is high.
@ TWR_DMA_PRIORITY_LOW
DMA channel priority is low.
@ TWR_DMA_CHANNEL_7
DMA channel 7.
@ TWR_DMA_CHANNEL_6
DMA channel 6.
@ TWR_DMA_CHANNEL_1
DMA channel 1.
@ TWR_DMA_CHANNEL_5
DMA channel 5, used for SPI.
@ TWR_DMA_CHANNEL_2
DMA channel 2.
@ TWR_DMA_CHANNEL_3
DMA channel 3.
@ TWR_DMA_CHANNEL_4
DMA channel 4.
@ TWR_DMA_MODE_CIRCULAR
DMA channel mode circular.
@ TWR_DMA_MODE_STANDARD
DMA channel mode standard.
DMA channel configuration.
twr_dma_mode_t mode
DMA channel mode.
twr_dma_direction_t direction
DMA channel direction.
twr_dma_request_t request
DMA channel request.
void * address_peripheral
Peripheral address.
twr_dma_size_t data_size_memory
DMA channel memory data size.
size_t length
DMA channel data length.
void * address_memory
RAM memory address.
twr_dma_size_t data_size_peripheral
DMA channel peripheral data size.
twr_dma_priority_t priority
DMA channel priority.