trafgen: xtrafgen.h File Reference

| trafgen Xilinx SDK Drivers API Documentation

- Overview
- Data Structures
- APIs
- File List
- Examples

Data Structures | Macros | Typedefs | Functions
xtrafgen.h File Reference

## Data Structures
struct | XTrafGen_CRamCmd
| Command Ram word fields. More...
struct | XTrafGen_PRamCmd
| Parameter Ram word fields. More...
struct | XTrafGen_Cmd
| Command structure exposed to user. More...
struct | XTrafGen_CmdEntry
| Command Entry structure. More...
struct | XTrafGen_Config
| The configuration structure for Traffic Generator device. More...
struct | XTrafGen_CmdInfo
| Command Information Structure. More...
struct | XTrafGen
| The XTrafGen driver instance data. More...

## Macros
#define | MAX_NUM_ENTRIES 256
| Number of command entries per region. More...
#define | NUM_BLOCKS 2
| Number of Read and write regions. More...
#define | XTG_WRITE 1
| Write Direction Flag. More...
#define | XTG_READ 0
| Read Direction Flag. More...
#define | XTG_MODE_FULL 0
| Full Mode. More...
#define | XTG_MODE_BASIC 1
| Basic Mode. More...
#define | XTG_MODE_STATIC 2
| Static Mode. More...
#define | XTG_MODE_STREAMING 3
| Streaming Mode. More...
#define | XTG_MODE_SYS_INIT 4
| System Init Mode. More...
#define | XTG_MWIDTH_32 0
| Master Width - 32. More...
#define | XTG_MWIDTH_64 1
| Master Width - 64. More...
#define | XTG_SWIDTH_32 0
| Slave Width - 32. More...
#define | XTG_SWIDTH_64 1
| Slave Width - 64. More...
#define | XTG_PRM_RAM_BLOCK_SIZE 0x400
| PARAM Block Size (1KB) More...
#define | XTG_CMD_RAM_BLOCK_SIZE 0x1000
| Cmd RAM Block Size (4KB) More...
#define | XTG_EXTCMD_RAM_BLOCK_SIZE 0x400
| Extended CMDRAM Block Size (1KB) More...
#define | XTG_PARAM_RAM_SIZE 0x800
| Parameter RAM (2KB) More...
#define | XTG_COMMAND_RAM_SIZE 0x2000
| Command RAM (8KB) More...
#define | XTG_MASTER_RAM_SIZE 0x2000
| Master RAM (8KB) More...
#define | XTrafGen_ReadCoreRevision(InstancePtr)
| XTrafGen_ReadCoreRevision reads revision of core. More...
#define | XTrafGen_ReadIdWidth(InstancePtr)
| XTrafGen_ReadIdWidth reads M_ID_WIDTH. More...
#define | XTrafGen_StartMasterLogic(InstancePtr)
| XTrafGen_StartMasterLogic starts traffic generator master logic. More...
#define | XTrafGen_IsMasterLogicDone(InstancePtr)
| XTrafGen_IsMasterLogicDone checks for traffic generator master logic completed bit. More...
#define | XTrafGen_LoopEnable(InstancePtr)
| XTrafGen_LoopEnable loops through the command set created using CMDRAM and PARAMRAM indefinitely in Advanced mode/Basic mode of ATG. More...
#define | XTrafGen_LoopDisable(InstancePtr)
| XTrafGen_LoopDisable Disables the loop bit in Master control regiset in Advanced mode/Basic mode of ATG. More...
#define | XTrafGen_WriteSlaveControlReg(InstancePtr, Value)
| XTrafGen_WriteSlaveControlReg enables control bits of Slave Control Register. More...
#define | XTrafGen_CheckforMasterComplete(InstancePtr)
| XTrafGen_CheckforMasterComplete checks for master complete. More...
#define | XTrafGen_ReadErrors(InstancePtr)
| XTrafGen_ReadErrors read master and slave errors. More...
#define | XTrafGen_EnableMasterCmpInterrupt(InstancePtr)
| XTrafGen_EnableMasterCmpInterrupt enables Master logic complete bit. More...
#define | XTrafGen_ClearMasterCmpInterrupt(InstancePtr)
| XTrafGen_ClearMasterCmpInterrupt clear Master logic complete interrupt bit. More...
#define | XTrafGen_ClearErrors(InstancePtr, Mask)
| XTrafGen_ClearErrors clear errors specified in Mask. More...
#define | XTrafGen_EnableErrors(InstancePtr, Mask)
| XTrafGen_EnableErrors enable errors specified in Mask. More...
#define | XTrafGen_MasterErrIntrEnable(InstancePtr)
| XTrafGen_MasterErrIntrEnable enables Global Master error bit. More...
#define | XTrafGen_MasterErrIntrDisable(InstancePtr)
| XTrafGen_MasterErrIntrDisable disables Global Master error bit. More...
#define | XTrafGen_SlaveErrIntrEnable(InstancePtr)
| XTrafGen_SlaveErrIntrEnable enables Global Slave error bit. More...
#define | XTrafGen_SlaveErrIntrDisable(InstancePtr)
| XTrafGen_SlaveErrIntrDisable disables Global Slave error bit. More...
#define | XTrafGen_ReadConfigStatus(InstancePtr)
| XTrafGen_ReadConfigStatus reads Config status register. More...
#define | XTrafGen_StaticEnable(InstancePtr)
| XTrafGen_StaticEnable enable the traffic generation when the core is configured Static Mode. More...
#define | XTrafGen_StaticDisable(InstancePtr)
| XTrafGen_StaticDisable disables the traffic generation on the Axi TrafGen when the core is configured in Static Mode. More...
#define | XTrafGen_StaticVersion(InstancePtr)
| XTrafGen_StaticVersion returns the version value for the Axi TrafGen When configured in Static Mode. More...
#define | XTrafGen_SetStaticBurstLen(InstancePtr, Value)
| XTrafGen_SetStaticBurstLen Configures the Burst Length for AxiTrafGen In Static Mode. More...
#define | XTrafGen_GetStaticBurstLen(InstancePtr)
| XTrafGen_GetStaticBurstLen Gets the Burst Length for AxiTrafGen in StaticMode. More...
#define | XTrafGen_GetStaticTransferDone(InstancePtr)
| XTrafGen_GetStaticTransferDone gets the state of Transfer done bit in Control register When the TraficGen is configured in Static Mode. More...
#define | XTrafGen_SetStaticTransferDone(InstancePtr)
| XTrafGen_SetStaticTransferDone sets the Transfer done bit in Control register When AxiTrafGen is Configured in Static Mode. More...
#define | XTrafGen_IsStaticTransferDone(InstancePtr)
| XTrafGen_IsStaticTransferDone checks for reset value When Static Traffic generation Completed by reading Control Register. More...
#define | XTrafGen_StreamEnable(InstancePtr)
| XTrafGen_StreamEnable enable the traffic generation on the Axi TrafGen When the core is configured in Streaming Mode. More...
#define | XTrafGen_StreamDisable(InstancePtr)
| XTrafGen_StreamDisable Disable the traffic generation on the Axi TrafGen When core is configured in Streaming Mode. More...
#define | XTrafGen_StreamVersion(InstancePtr)
| XTrafGen_StreamVersion returns the version value for the Axi TrafGen When configured in Streaming Mode. More...
#define | XTrafGen_SetStreamingTransLen(InstancePtr, Value)
| XTrafGen_SetStreamingTransLen Configures the length of transaction for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_GetStreamingTransLen(InstancePtr)
| XTrafGen_GetStreamingTransLen Gets the length of transaction for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_GetStreamingTransCnt(InstancePtr)
| XTrafGen_GetStreamingTransCnt Gets the transfer count for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_SetStreamingRandomLen(InstancePtr, Value)
| XTrafGen_SetStreamingRandomLen Configures the random transaction length for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_GetStreamingProgDelay(InstancePtr)
| XTrafGen_GetStreamingProgDelay Gets the Programmable Delay for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_SetStreamingTransCnt(InstancePtr, Value)
| XTrafGen_SetStreamingTransCnt Configures the transfer count for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_SetStreamingProgDelay(InstancePtr, Value)
| XTrafGen_SetStreamingProgDelay Configures the Programmable Delay for AxiTrafGen in Streaming Mode. More...
#define | XTrafGen_SetStreamingTdestPort(InstancePtr, Value)
| XTrafGen_SetStreamingTdestPort Configures the Value to drive on TDEST port for Axi TrafGen in Streaming Mode. More...
#define | XTrafGen_SetStreamingTransferDone(InstancePtr)
| XTrafGen_SetTransferDone sets the Transfer done bit in Control register When AxiTrafGen is Configured in Streaming Mode. More...
#define | XTrafGen_IsStreamingTransferDone(InstancePtr)
| XTrafGen_IsStreamingTransferDone checks for reset value When Streaming Traffic generation is Completed by reading Stream Control Register. More...
#define | XTrafGen_ResetStreamingRandomLen(InstancePtr)
| XTrafGen_ResetStreamingRandomLen resets the random transaction length for AxiTrafGen in Streaming Mode. More...

## Typedefs
typedef struct XTrafGen_CRamCmd | XTrafGen_CRamCmd
| Command Ram word fields. More...
typedef struct XTrafGen_PRamCmd | XTrafGen_PRamCmd
| Parameter Ram word fields. More...
typedef struct XTrafGen_Cmd | XTrafGen_Cmd
| Command structure exposed to user. More...
typedef struct XTrafGen_CmdEntry | XTrafGen_CmdEntry
| Command Entry structure. More...
typedef struct XTrafGen_Config | XTrafGen_Config
| The configuration structure for Traffic Generator device. More...
typedef struct XTrafGen_CmdInfo | XTrafGen_CmdInfo
| Command Information Structure. More...
typedef struct XTrafGen | XTrafGen
| The XTrafGen driver instance data. More...

## Functions
int | XTrafGen_CfgInitialize (XTrafGen *InstancePtr, XTrafGen_Config *Config, UINTPTR EffectiveAddress)
| This function initializes a AXI Traffic Generator device. More...
XTrafGen_Config * | XTrafGen_LookupConfig (u32 DeviceId)
| Look up the hardware configuration for a device instance. More...
int | XTrafGen_AddCommand (XTrafGen *InstancePtr, XTrafGen_Cmd *CmdPtr)
| Add a command to the software list of commands. More...
int | XTrafGen_GetLastValidIndex (XTrafGen *InstancePtr, u32 RdWrFlag)
| Get last Valid Command Index of Write/Read region. More...
int | XTrafGen_WriteCmdsToHw (XTrafGen *InstancePtr)
| Write Commands to internal Command and Parameter RAMs. More...
void | XTrafGen_AccessMasterRam (XTrafGen *InstancePtr, u32 Offset, int Length, u8 RdWrFlag, u32 *Data)
| Write or Read Master RAM. More...
void | XTrafGen_PrintCmds (XTrafGen *InstancePtr)
| Display Command Entry values. More...
int | XTrafGen_EraseAllCommands (XTrafGen *InstancePtr)
| Erase all Command Entry values. More...