![]() |
tmrctr
Vitis Drivers API Documentation
|
This file contains a design example using the Timer Counter driver (XTmrCtr) and hardware device in a polled mode.
None.
MODIFICATION HISTORY:
Ver Who Date Changes
1.00b jhl 02/13/02 First release 1.00b sv 04/26/05 Minor changes to comply to Doxygen and coding guidelines. 2.00a ktn 11/26/09 Minor changes as per coding guidelines. 4.2 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. 4.15 bdk 12/08/25 Updated comments to support SDT flow for Doxygen documentation.
Functions | |
| int | TmrCtrPolledExample (UINTPTR BaseAddr, u8 TmrCtrNumber) |
| This function does a minimal test on the timer counter device and driver as a design example. More... | |
| int | main (void) |
| Main function to call the polled example. More... | |
| int main | ( | void | ) |
Main function to call the polled example.
| None. |
References TmrCtrPolledExample().
| int TmrCtrPolledExample | ( | UINTPTR | BaseAddr, |
| u8 | TmrCtrNumber | ||
| ) |
This function does a minimal test on the timer counter device and driver as a design example.
The purpose of this function is to illustrate how to use the XTmrCtr component in a polled mode.
| BaseAddr | is the base address of the device |
| TmrCtrNumber | is the timer counter of the device to operate on. Each device may contain multiple timer counters. The timer number is a zero based number with a range of 0 - (XTC_DEVICE_TIMER_COUNT - 1). |
References XTmrCtr_GetValue(), XTmrCtr_Initialize(), XTmrCtr_SelfTest(), XTmrCtr_SetOptions(), and XTmrCtr_Start().
Referenced by main().