hwicap
Xilinx SDK Drivers API Documentation
xhwicap_testapp_example.c File Reference

Overview

This file contains a design example using the HwIcap device driver and hardware device.

Note

This example can be run on a 7 series device, Zynq device, Ultrascale and ZynqMP Ultrascale FPGAs.

In a Zynq device the ICAP needs to be selected using the XDcfg_SelectIcapInterface API of the DevCfg driver (clear the PCAP_PR bit of Control register in the Device Config Interface) before it can be accessed using the HwIcap. In case of ZynqMP clear the PCAP_PR bit of pcap_ctrl register in Module Configuration Security Unit(CSU) using register write.

MODIFICATION HISTORY:
Ver   Who  Date     Changes

2.00a sv 10/04/07 Initial release. 11.0 ms 01/23/17 Added xil_printf statement in main function to ensure that "Successfully ran" and "Failed" strings are available in all examples. This is a fix for CR-965028.

Functions

int HwIcapTestAppExample (u16 HwIcapDeviceId)
 The purpose of this function is to illustrate the usage of the HwIcap driver. More...
 
int main (void)
 Main function to call the HwIcap example. More...
 

Function Documentation

◆ HwIcapTestAppExample()

int HwIcapTestAppExample ( u16  HwIcapDeviceId)

The purpose of this function is to illustrate the usage of the HwIcap driver.

Parameters
HwIcapDeviceIdis device ID of the XHwIcap Device, typically XPAR_<HWICAP_instance>_DEVICE_ID value from xparameters.h
Returns
XST_SUCCESS to indicate success, otherwise XST_FAILURE.
Note
None.

References XHwIcap_Config::BaseAddress, XHwIcap_CfgInitialize(), XHwIcap_GetConfigReg(), XHwIcap_LookupConfig(), and XHwIcap_SelfTest().

Referenced by main().

◆ main()

int main ( void  )

Main function to call the HwIcap example.

This function is not included if the example is generated from the TestAppGen test tool.

Parameters
None.
Returns
XST_SUCCESS to indicate success, otherwise XST_FAILURE.
Note
None.

References HwIcapTestAppExample().