iLLD_TC29x  1.0
IfxDma.h File Reference

DMA basic functionality. More...

#include "_Impl/IfxDma_cfg.h"
#include "IfxDma_bf.h"
#include "Cpu/Std/IfxCpu_Intrinsics.h"
#include "IfxDma_reg.h"
#include "Src/Std/IfxSrc.h"
#include "Scu/Std/IfxScuWdt.h"
#include "Scu/Std/IfxScuCcu.h"

Go to the source code of this file.

Enumerations

enum  IfxDma_BusMasterMode {
  IfxDma_BusMasterMode_user = 0,
  IfxDma_BusMasterMode_supervisor = 1
}
 Bus Master Mode definition Definition in Ifx_DMA.MODE[4].B.MODE. More...
 
enum  IfxDma_ChannelBusPriority {
  IfxDma_ChannelBusPriority_low = 0,
  IfxDma_ChannelBusPriority_medium = 1,
  IfxDma_ChannelBusPriority_high = 2
}
 Channel Bus Priority definition. More...
 
enum  IfxDma_ChannelIncrementCircular {
  IfxDma_ChannelIncrementCircular_none = 0,
  IfxDma_ChannelIncrementCircular_2 = 1,
  IfxDma_ChannelIncrementCircular_4 = 2,
  IfxDma_ChannelIncrementCircular_8 = 3,
  IfxDma_ChannelIncrementCircular_16 = 4,
  IfxDma_ChannelIncrementCircular_32 = 5,
  IfxDma_ChannelIncrementCircular_64 = 6,
  IfxDma_ChannelIncrementCircular_128 = 7,
  IfxDma_ChannelIncrementCircular_256 = 8,
  IfxDma_ChannelIncrementCircular_512 = 9,
  IfxDma_ChannelIncrementCircular_1024 = 10,
  IfxDma_ChannelIncrementCircular_2048 = 11,
  IfxDma_ChannelIncrementCircular_4096 = 12,
  IfxDma_ChannelIncrementCircular_8192 = 13,
  IfxDma_ChannelIncrementCircular_16384 = 14,
  IfxDma_ChannelIncrementCircular_32768 = 15
}
 DMA circular buffer (wrap around) definition Definition in Ifx_DMA.CH[64].ADICR.B.CBLS and Ifx_DMA.CH[64].ADICR.B.CBLD. More...
 
enum  IfxDma_ChannelIncrementDirection {
  IfxDma_ChannelIncrementDirection_negative = 0,
  IfxDma_ChannelIncrementDirection_positive = 1
}
 DMA incrementation direction definition Definition in Ifx_DMA.CH[64].ADICR.B.INCS. More...
 
enum  IfxDma_ChannelIncrementStep {
  IfxDma_ChannelIncrementStep_1 = 0,
  IfxDma_ChannelIncrementStep_2 = 1,
  IfxDma_ChannelIncrementStep_4 = 2,
  IfxDma_ChannelIncrementStep_8 = 3,
  IfxDma_ChannelIncrementStep_16 = 4,
  IfxDma_ChannelIncrementStep_32 = 5,
  IfxDma_ChannelIncrementStep_64 = 6,
  IfxDma_ChannelIncrementStep_128 = 7
}
 DMA incrementation definition Definition in Ifx_DMA.CH[64].ADICR.B.SMF. More...
 
enum  IfxDma_ChannelInterruptControl {
  IfxDma_ChannelInterruptControl_thresholdLimitMatch = 0,
  IfxDma_ChannelInterruptControl_transferCountDecremented = 1
}
 Channel Transfer Interrupt generation mechanism. Definition in Ifx_DMA.CH[64].ADICR.B.INTCT (bit 0) More...
 
enum  IfxDma_ChannelMove {
  IfxDma_ChannelMove_1 = 0,
  IfxDma_ChannelMove_2 = 1,
  IfxDma_ChannelMove_4 = 2,
  IfxDma_ChannelMove_8 = 3,
  IfxDma_ChannelMove_16 = 4,
  IfxDma_ChannelMove_3 = 5,
  IfxDma_ChannelMove_5 = 6,
  IfxDma_ChannelMove_9 = 7
}
 DMA transfer definition Definition in Ifx_DMA.BLK0.ME.CHCR.B.BLKM and Ifx_DMA.BLK1.ME.CHCR.B.BLKM. More...
 
enum  IfxDma_ChannelMoveSize {
  IfxDma_ChannelMoveSize_8bit = 0,
  IfxDma_ChannelMoveSize_16bit = 1,
  IfxDma_ChannelMoveSize_32bit = 2,
  IfxDma_ChannelMoveSize_64bit = 3,
  IfxDma_ChannelMoveSize_128bit = 4,
  IfxDma_ChannelMoveSize_256bit = 5
}
 DMA move size definition Definition in Ifx_DMA.BLK0.ME.CHCR.B.CHDW and Ifx_DMA.BLK1.ME.CHCR.B.CHDW. More...
 
enum  IfxDma_ChannelOperationMode {
  IfxDma_ChannelOperationMode_single = 0,
  IfxDma_ChannelOperationMode_continuous = 1
}
 DMA operation mode Definition in Ifx_DMA.BLK0.ME.CHCR.B.CHMODE and Ifx_DMA.BLK1.ME.CHCR.B.CHMODE. More...
 
enum  IfxDma_ChannelPattern {
  IfxDma_ChannelPattern_0_disable = 0,
  IfxDma_ChannelPattern_0_mode1 = 1,
  IfxDma_ChannelPattern_0_mode2 = 2,
  IfxDma_ChannelPattern_0_mode3 = 3,
  IfxDma_ChannelPattern_1_disable = 4,
  IfxDma_ChannelPattern_1_mode1 = 5,
  IfxDma_ChannelPattern_1_mode2 = 6,
  IfxDma_ChannelPattern_1_mode3 = 7
}
 Pattern detection selection Definition in Ifx_DMA.BLK0.ME.CHCR.B.PATSEL and Ifx_DMA.BLK1.ME.CHCR.B.PATSEL. More...
 
enum  IfxDma_ChannelPriority {
  IfxDma_ChannelPriority_low = 0,
  IfxDma_ChannelPriority_medium = 1,
  IfxDma_ChannelPriority_high = 2
}
 Channel Priority definition. More...
 
enum  IfxDma_ChannelRequestMode {
  IfxDma_ChannelRequestMode_oneTransferPerRequest = 0,
  IfxDma_ChannelRequestMode_completeTransactionPerRequest = 1
}
 DMA request mode Definition in Ifx_DMA.BLK0.ME.CHCR.B.RROAT and Ifx_DMA.BLK1.ME.CHCR.B.RROAT. More...
 
enum  IfxDma_ChannelRequestSource {
  IfxDma_ChannelRequestSource_peripheral = 0,
  IfxDma_ChannelRequestSource_daisyChain = 1
}
 DMA request selection Definition in Ifx_DMA.BLK0.ME.CHCR.B.PRSEL and Ifx_DMA.BLK1.ME.CHCR.B.PRSEL. More...
 
enum  IfxDma_ChannelShadow {
  IfxDma_ChannelShadow_none = 0,
  IfxDma_ChannelShadow_src = 1,
  IfxDma_ChannelShadow_dst = 2,
  IfxDma_ChannelShadow_srcDirectWrite = 5,
  IfxDma_ChannelShadow_dstDirectWrite = 6,
  IfxDma_ChannelShadow_doubleSourceBufferingSwSwitch = 8,
  IfxDma_ChannelShadow_doubleSourceBufferingHwSwSwitch = 9,
  IfxDma_ChannelShadow_doubleDestinationBufferingSwSwitch = 10,
  IfxDma_ChannelShadow_doubleDestinationBufferingHwSwSwitch = 11,
  IfxDma_ChannelShadow_linkedList = 12,
  IfxDma_ChannelShadow_accumulatedLinkedList = 13,
  IfxDma_ChannelShadow_safeLinkedList = 14,
  IfxDma_ChannelShadow_conditionalLinkedList = 15
}
 shadow definition definition Definition in Ifx_DMA.CH[64].ADICR.B.SHCT More...
 
enum  IfxDma_HardwareResourcePartition {
  IfxDma_HardwareResourcePartition_0 = 0,
  IfxDma_HardwareResourcePartition_1,
  IfxDma_HardwareResourcePartition_2,
  IfxDma_HardwareResourcePartition_3
}
 
enum  IfxDma_MoveEngine {
  IfxDma_MoveEngine_0 = 0,
  IfxDma_MoveEngine_1 = 1
}
 DMA move engine definition. More...
 
enum  IfxDma_SleepMode {
  IfxDma_SleepMode_enable = 0,
  IfxDma_SleepMode_disable = 1
}
 Enable/disable the sensitivity of the module to sleep signal
Definition in Ifx_DMA.CLC.B.EDIS. More...
 

Functions

IFX_INLINE boolean IfxDma_isChannelReset (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return the status of a DMA channel (reset / not reset) More...
 
IFX_INLINE void IfxDma_resetChannel (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Reset the channel. More...
 
IFX_INLINE void IfxDma_clearChannelTransactionRequestLost (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Clear the channel transaction request lost flag status. More...
 
IFX_INLINE void IfxDma_disableChannelTransaction (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Disable a DMA channel hardware transaction request. More...
 
IFX_INLINE void IfxDma_disableChannelTransactionLostError (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Disable the generation of a channel transaction lost error interrupt. More...
 
IFX_INLINE void IfxDma_enableChannelTransaction (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Enable a DMA channel hardware transaction request. More...
 
IFX_INLINE void IfxDma_enableChannelTransactionLostError (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Enable the generation of a channel transaction lost error interrupt. More...
 
IFX_INLINE boolean IfxDma_getChannelTransactionRequestLost (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Check the channel transaction request lost flag status. More...
 
IFX_INLINE
IfxDma_ChannelIncrementCircular 
IfxDma_getCircularRangeCode (uint16 range)
 Converts DMA circular range to circular code. More...
 
IFX_INLINE boolean IfxDma_isChannelTransactionEnabled (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return the hardware transaction request status of a DMA channel. More...
 
IFX_INLINE boolean IfxDma_isChannelTransactionPending (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return the status of a DMA channel (transaction pending) More...
 
IFX_INLINE void IfxDma_setSleepMode (Ifx_DMA *dma, IfxDma_SleepMode mode)
 Sets the sensitivity of the module to sleep signal. More...
 
IFX_INLINE void IfxDma_startChannelTransaction (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Request a DMA channel transaction. More...
 
IFX_INLINE void IfxDma_clearErrorFlags (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine, uint32 mask)
 Clear the DMA error status flags. More...
 
IFX_INLINE void IfxDma_disableMoveEngineDestinationError (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine)
 Disable the generation of a Move engine destination error interrupt. More...
 
IFX_INLINE void IfxDma_disableMoveEngineSourceError (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine)
 Disable the generation of a Move engine source error interrupt. More...
 
IFX_INLINE void IfxDma_enableMoveEngineDestinationError (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine)
 Enable the generation of a Move engine destination error interrupt. More...
 
IFX_INLINE void IfxDma_enableMoveEngineSourceError (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine)
 Enable the generation of a Move engine source error interrupt. More...
 
IFX_INLINE uint32 IfxDma_getErrorFlags (Ifx_DMA *dma, IfxDma_MoveEngine moveEngine)
 Return the DMA error status flags. More...
 
IFX_INLINE uint32 IfxDma_getChannelDestinationAddress (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Get a channel source address. More...
 
IFX_INLINE uint32 IfxDma_getChannelSourceAddress (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Get a channel source address. More...
 
IFX_INLINE uint32 IfxDma_getChannelTransferCount (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return remaining DMA transfer count. More...
 
IFX_INLINE uint32 IfxDma_getTimestamp (Ifx_DMA *dma)
 get the time stamp More...
 
IFX_INLINE void IfxDma_setChannelBlockMode (Ifx_DMA *dma, IfxDma_ChannelId channelId, IfxDma_ChannelMove blockMode)
 Configure the move count for each DMA channel transfer. More...
 
IFX_INLINE void IfxDma_setChannelContinuousMode (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure a DMA channel to "continous transaction mode" After a transaction, the hardware request transaction remain enabled. More...
 
IFX_INLINE void IfxDma_setChannelDestinationAddress (Ifx_DMA *dma, IfxDma_ChannelId channelId, void *address)
 Configure the destination address. More...
 
IFX_INLINE void IfxDma_setChannelDestinationIncrementStep (Ifx_DMA *dma, IfxDma_ChannelId channelId, IfxDma_ChannelIncrementStep incStep, IfxDma_ChannelIncrementDirection direction, IfxDma_ChannelIncrementCircular size)
 Configure a DMA channel destination pointer. More...
 
IFX_INLINE void IfxDma_setChannelMoveSize (Ifx_DMA *dma, IfxDma_ChannelId channelId, IfxDma_ChannelMoveSize moveSize)
 Configure a DMA channel move. More...
 
IFX_INLINE void IfxDma_setChannelShadow (Ifx_DMA *dma, IfxDma_ChannelId channelId, IfxDma_ChannelShadow shadow)
 Configure a DMA channel shadow pointer. More...
 
IFX_INLINE void IfxDma_setChannelSingleMode (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure a DMA channel to "single transaction mode" After a transaction, the hardware request transaction is disabled, and must be set by software again. More...
 
IFX_INLINE void IfxDma_setChannelSingleTransaction (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure a DMA channel to "single transaction mode" One transfer request starts a complete DMA transaction. More...
 
IFX_INLINE void IfxDma_setChannelSingleTransfer (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure a DMA channel to "single transfer mode" A transfer request is required for each transfer. More...
 
IFX_INLINE void IfxDma_setChannelSourceAddress (Ifx_DMA *dma, IfxDma_ChannelId channelId, const void *address)
 Configure the source address. More...
 
IFX_INLINE void IfxDma_setChannelSourceIncrementStep (Ifx_DMA *dma, IfxDma_ChannelId channelId, IfxDma_ChannelIncrementStep incStep, IfxDma_ChannelIncrementDirection direction, IfxDma_ChannelIncrementCircular size)
 Configure a DMA channel source pointer. More...
 
IFX_INLINE void IfxDma_setChannelTransferCount (Ifx_DMA *dma, IfxDma_ChannelId channelId, uint32 transferCount)
 Configure the move count of a DMA channel transaction. More...
 
IFX_INLINE void IfxDma_writeChannelShadowDisable (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure the shadow pointer register to read only. More...
 
IFX_INLINE void IfxDma_writeChannelShadowEnable (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Configure the shadow pointer register to write-able. More...
 
IFX_INLINE void IfxDma_clearChannelHalt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Clear channel halt request and aknowledgement. More...
 
IFX_INLINE boolean IfxDma_getChannelHalt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Get channel halt aknowledgement. More...
 
IFX_INLINE void IfxDma_setChannelHalt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 setting channel halt request More...
 
IFX_INLINE boolean IfxDma_getDoubleBufferRead (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 get information on buffer being read by software and clear the notification flag More...
 
IFX_INLINE boolean IfxDma_getDoubleBufferSelection (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 get Double buffer selection More...
 
IFX_INLINE void IfxDma_keepDoubleBufferActive (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 keeps the double buffer active More...
 
IFX_INLINE void IfxDma_switchDoubleBuffer (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Double buffer switch application. More...
 
IFX_INLINE void IfxDma_clearChannelInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Clear a channel transfer interrupt flag. More...
 
IFX_INLINE void IfxDma_disableChannelInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Disable channel interrupt trigger. More...
 
IFX_INLINE void IfxDma_enableChannelInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Enable channel interrupt trigger. More...
 
IFX_INLINE boolean IfxDma_getAndClearChannelInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return and clear a channel transfer interrupt flag The flag is automatically cleared with the call to this function. More...
 
IFX_INLINE boolean IfxDma_getAndClearChannelPatternDetectionInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Returns and clears the pattern detection interrupt flag. More...
 
IFX_INLINE boolean IfxDma_getAndClearChannelWrapDestinationBufferInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Returns and clears the status of channel wrap destination buffer interrupt trigger flag. More...
 
IFX_INLINE boolean IfxDma_getAndClearChannelWrapSourceBufferInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Returns and clears the status of channel wrap source buffer interrupt trigger flag. More...
 
IFX_INLINE boolean IfxDma_getChannelInterrupt (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Return a channel transfer interrupt flag. More...
 
IFX_INLINE boolean IfxDma_getChannelPatternDetectionOldValue (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Returns whether the old value of pattern detection corresponding pattern comparison operation found a pattern match in previous DMA * read move or not. More...
 
IFX_INLINE volatile Ifx_SRC_SRCR * IfxDma_getSrcPointer (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Returns the SRC pointer for given DMA channel. More...
 
IFX_INLINE void IfxDma_setChannelInterruptServiceRequest (Ifx_DMA *dma, IfxDma_ChannelId channelId)
 Setting of channel interrupt service request by software. More...
 

Detailed Description

DMA basic functionality.

Version
iLLD_1_0_0_11_0
                            IMPORTANT NOTICE

Infineon Technologies AG (Infineon) is supplying this file for use exclusively with Infineon's microcontroller products. This file can be freely distributed within development tools that are supporting such microcontroller products.

THIS SOFTWARE IS PROVIDED "AS IS". NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. INFINEON SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.

Definition in file IfxDma.h.