35 #if defined( LDMA_PRESENT ) && ( LDMA_COUNT == 1 )
53 #if defined( LDMA_IRQ_HANDLER_TEMPLATE )
58 void LDMA_IRQHandler(
void)
72 uint32_t mask = 0x1 << ch;
114 EFM_ASSERT(ch < DMA_CHAN_COUNT);
139 EFM_ASSERT(init != NULL);
160 LDMA->IFC = 0xFFFFFFFF;
189 uint32_t chMask = 1 << ch;
191 EFM_ASSERT(ch < DMA_CHAN_COUNT);
192 EFM_ASSERT(transfer != NULL);
233 LDMA->REQDIS |= chMask;
238 LDMA->DBGHALT |= chMask;
268 LDMA->LINKLOAD = chMask;
286 uint32_t chMask = 1 << ch;
288 EFM_ASSERT(ch < DMA_CHAN_COUNT);
291 LDMA->IEN &= ~chMask;
309 uint32_t chMask = 1 << ch;
311 EFM_ASSERT(ch < DMA_CHAN_COUNT);
314 if (((
LDMA->CHEN & chMask) == 0)
315 && ((
LDMA->CHDONE & chMask) == chMask))
340 uint32_t remaining, done, iflag;
341 uint32_t chMask = 1 << ch;
343 EFM_ASSERT(ch < DMA_CHAN_COUNT);
348 remaining =
LDMA->CH[ch].CTRL;
356 if (done || ((remaining == 0) && iflag))
361 return remaining + 1;
Clock management unit (CMU) API.
DMA transfer configuration structure.
uint8_t ldmaCtrlSyncPrsSetOn
#define _LDMA_CTRL_SYNCPRSCLREN_SHIFT
uint8_t ldmaInitCtrlSyncPrsSetEn
#define CORE_DECLARE_IRQ_STATE
uint32_t LDMA_TransferRemainingCount(int ch)
Get number of items remaining in a transfer.
#define _LDMA_CTRL_NUMFIXED_MASK
__STATIC_INLINE uint32_t LDMA_IntGetEnabled(void)
Get enabled and pending LDMA interrupt flags. Useful for handling more interrupt sources in the same ...
Emlib peripheral API "assert" implementation.
void LDMA_Init(const LDMA_Init_t *init)
Initialize the LDMA controller.
#define _LDMA_CTRL_SYNCPRSSETEN_MASK
RAM and peripheral bit-field set and clear API.
#define _LDMA_CH_LOOP_LOOPCNT_SHIFT
uint8_t ldmaCtrlSyncPrsClrOn
#define _LDMA_CH_CFG_DSTINCSIGN_MASK
#define _LDMA_CH_LINK_LINKADDR_MASK
#define _LDMA_CH_CTRL_XFERCNT_MASK
void LDMA_StartTransfer(int ch, const LDMA_TransferCfg_t *transfer, const LDMA_Descriptor_t *descriptor)
Start a DMA transfer.
#define _LDMA_CH_CFG_ARBSLOTS_SHIFT
uint8_t ldmaCfgDstIncSign
void LDMA_StopTransfer(int ch)
Stop a DMA transfer.
#define _LDMA_CTRL_NUMFIXED_SHIFT
#define _LDMA_CH_CFG_ARBSLOTS_MASK
#define _LDMA_CH_REQSEL_MASK
#define _LDMA_CTRL_SYNCPRSSETEN_SHIFT
#define _LDMA_CH_CTRL_XFERCNT_SHIFT
#define CORE_ENTER_ATOMIC()
#define CORE_ATOMIC_SECTION(yourcode)
void LDMA_DeInit(void)
De-initialize the LDMA controller.
#define _LDMA_CH_LOOP_LOOPCNT_MASK
uint8_t ldmaInitCtrlSyncPrsClrEn
Core interrupt handling API.
void CMU_ClockEnable(CMU_Clock_TypeDef clock, bool enable)
Enable/disable a clock.
#define _LDMA_CTRL_SYNCPRSCLREN_MASK
uint8_t ldmaCtrlSyncPrsClrOff
#define _LDMA_CH_CFG_SRCINCSIGN_SHIFT
bool LDMA_TransferDone(int ch)
Check if a DMA transfer has completed.
uint8_t ldmaCtrlSyncPrsSetOff
#define CORE_EXIT_ATOMIC()
Direct memory access (LDMA) API.
__STATIC_INLINE void BUS_RegMaskedClear(volatile uint32_t *addr, uint32_t mask)
Perform a masked clear operation on peripheral register address.
LDMA initialization configuration structure.
uint8_t ldmaInitCtrlNumFixed
uint8_t ldmaInitIrqPriority
#define _LDMA_CH_CFG_SRCINCSIGN_MASK
__STATIC_INLINE void BUS_RegBitWrite(volatile uint32_t *addr, unsigned int bit, unsigned int val)
Perform a single-bit write operation on a peripheral register.
#define _LDMA_CH_CFG_DSTINCSIGN_SHIFT
uint8_t ldmaCfgSrcIncSign
void LDMA_EnableChannelRequest(int ch, bool enable)
Enable or disable a LDMA channel request.