![]() |
canfd
Xilinx SDK Drivers API Documentation
|
Contains an example of how to use the XCan driver directly.
The example here shows using the driver/device in interrupt mode.
This code assumes that Xilinx interrupt controller (XIntc) is used in the system to forward the CAN device interrupt output to the processor and no operating system is being used.
The Baud Rate Prescaler Register (BRPR) and Bit Timing Register (BTR) are setup such that CAN baud rate equals 40Kbps, assuming that the the CAN clock is 24MHz. The user needs to modify these values based on the desired baud rate and the CAN clock frequency. For more information see the CAN 2.0A, CAN 2.0B, ISO 11898-1 specifications.
MODIFICATION HISTORY:
Ver Who Date Changes
1.0 nsk 06/04/15 First release 1.2 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. ms 04/05/17 Added tabspace for return statements in functions for proper documentation while generating doxygen.
Functions | |
int | main () |
This function is the main function of the Can interrupt example. More... | |
int main | ( | void | ) |
This function is the main function of the Can interrupt example.
None. |