ttcps
Xilinx SDK Drivers API Documentation
xttcps_tapp_example.c File Reference

Overview

This file contains an example uses ttc to generate interrupt and update a flag which is checked in interrupt example to confirm whether the interrupt is generated or not.

Note
  MODIFICATION HISTORY:
  Ver  Who    Date     Changes

3.00 pkp 01/12/15 First release 3.01 pkp 01/30/16 Modified SetupTimer to remove XTtcps_Stop before TTC configuration as it is added in xttcps.c in XTtcPs_CfgInitialize 3.01 pkp 03/04/16 Added status check after SetupTicker is called by TmrInterruptExample 3.2 mus 10/28/16 Updated TmrCntrSetup as per prototype of XTtcPs_CalcIntervalFromFreq ms 01/23/17 Modified 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 TmrInterruptExample (XTtcPs *TtcPsInst, u16 DeviceID, u16 TtcTickIntrID, XScuGic *InterruptController)
 This is the main function of the interrupt example. More...
 
int main (void)
 This is the main function that calls the TTC interrupt example. More...
 

Function Documentation

◆ main()

int main ( void  )

This is the main function that calls the TTC interrupt example.

Parameters
None
Returns
  • XST_SUCCESS to indicate Success
  • XST_FAILURE to indicate a Failure.
Note
None.

References TmrInterruptExample().

◆ TmrInterruptExample()

int TmrInterruptExample ( XTtcPs TtcPsInst,
u16  DeviceID,
u16  TtcTickIntrID,
XScuGic *  InterruptController 
)

This is the main function of the interrupt example.

Parameters
TtcPsInstis a pointer to the ttc instance.
DeviceIDis the unique ID for the device.
TtcTickIntrIDis the unique interrupt ID for the timer.
InterruptControlleris a pointer to the interrupt controller instance..
Returns
XST_SUCCESS to indicate success, else XST_FAILURE to indicate a Failure.

Referenced by main().