tpg
Vitis Drivers API Documentation
tpg_selftest_example.c File Reference

Overview

This file contains an example using the XTpg driver to do self test on the device.

Note

None

MODIFICATION HISTORY:

Ver   Who    Date     Changes


3.0 adk 01/15/14 First release ms 04/10/17 Modified filename tag to include the file in doxygen examples.

Macros

#define TPG_DEVICE_ID   XPAR_TPG_0_DEVICE_ID
 TPG Device ID. More...
 

Functions

int XTpgSelfTestExample (u16 DeviceId)
 This function does a minimal test on the XTpg driver. More...
 
int main (void)
 Main function to call the example. More...
 

Variables

XTpg Tpg
 Instance of the TPG Device. More...
 

Macro Definition Documentation

#define TPG_DEVICE_ID   XPAR_TPG_0_DEVICE_ID

TPG Device ID.

Referenced by main().

Function Documentation

int main ( void  )

Main function to call the example.

Returns
  • XST_SUCCESS if XTpgSelfTestExample is successful.
    • XST_FAILURE if XTpgSelfTestExample is failed.
Note
None

References TPG_DEVICE_ID, and XTpgSelfTestExample().

int XTpgSelfTestExample ( u16  DeviceId)

This function does a minimal test on the XTpg driver.

Parameters
DeviceIdis the XPAR_<TPG_instance>_DEVICE_ID value from xparameters.h.
Returns
  • XST_SUCCESS if successful
    • XST_FAILURE if failed.
Note
None

References XTpg_Config::BaseAddress, XTpg_CfgInitialize(), XTpg_LookupConfig(), and XTpg_SelfTest().

Referenced by main().

Variable Documentation

XTpg Tpg

Instance of the TPG Device.